2
0

curl.1 92 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118
  1. .\" **************************************************************************
  2. .\" * _ _ ____ _
  3. .\" * Project ___| | | | _ \| |
  4. .\" * / __| | | | |_) | |
  5. .\" * | (__| |_| | _ <| |___
  6. .\" * \___|\___/|_| \_\_____|
  7. .\" *
  8. .\" * Copyright (C) 1998 - 2014, Daniel Stenberg, <daniel@haxx.se>, et al.
  9. .\" *
  10. .\" * This software is licensed as described in the file COPYING, which
  11. .\" * you should have received as part of this distribution. The terms
  12. .\" * are also available at http://curl.haxx.se/docs/copyright.html.
  13. .\" *
  14. .\" * You may opt to use, copy, modify, merge, publish, distribute and/or sell
  15. .\" * copies of the Software, and permit persons to whom the Software is
  16. .\" * furnished to do so, under the terms of the COPYING file.
  17. .\" *
  18. .\" * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
  19. .\" * KIND, either express or implied.
  20. .\" *
  21. .\" **************************************************************************
  22. .\"
  23. .TH curl 1 "27 July 2012" "Curl 7.27.0" "Curl Manual"
  24. .SH NAME
  25. curl \- transfer a URL
  26. .SH SYNOPSIS
  27. .B curl [options]
  28. .I [URL...]
  29. .SH DESCRIPTION
  30. .B curl
  31. is a tool to transfer data from or to a server, using one of the supported
  32. protocols (DICT, FILE, FTP, FTPS, GOPHER, HTTP, HTTPS, IMAP, IMAPS, LDAP,
  33. LDAPS, POP3, POP3S, RTMP, RTSP, SCP, SFTP, SMTP, SMTPS, TELNET and TFTP). The
  34. command is designed to work without user interaction.
  35. curl offers a busload of useful tricks like proxy support, user
  36. authentication, FTP upload, HTTP post, SSL connections, cookies, file transfer
  37. resume, Metalink, and more. As you will see below, the number of features will
  38. make your head spin!
  39. curl is powered by libcurl for all transfer-related features. See
  40. .BR libcurl (3)
  41. for details.
  42. .SH URL
  43. The URL syntax is protocol-dependent. You'll find a detailed description in
  44. RFC 3986.
  45. You can specify multiple URLs or parts of URLs by writing part sets within
  46. braces as in:
  47. http://site.{one,two,three}.com
  48. or you can get sequences of alphanumeric series by using [] as in:
  49. ftp://ftp.numericals.com/file[1-100].txt
  50. ftp://ftp.numericals.com/file[001-100].txt (with leading zeros)
  51. ftp://ftp.letters.com/file[a-z].txt
  52. Nested sequences are not supported, but you can use several ones next to each
  53. other:
  54. http://any.org/archive[1996-1999]/vol[1-4]/part{a,b,c}.html
  55. You can specify any amount of URLs on the command line. They will be fetched
  56. in a sequential manner in the specified order.
  57. You can specify a step counter for the ranges to get every Nth number or
  58. letter:
  59. http://www.numericals.com/file[1-100:10].txt
  60. http://www.letters.com/file[a-z:2].txt
  61. If you specify URL without protocol:// prefix, curl will attempt to guess what
  62. protocol you might want. It will then default to HTTP but try other protocols
  63. based on often-used host name prefixes. For example, for host names starting
  64. with "ftp." curl will assume you want to speak FTP.
  65. curl will do its best to use what you pass to it as a URL. It is not trying to
  66. validate it as a syntactically correct URL by any means but is instead
  67. \fBvery\fP liberal with what it accepts.
  68. curl will attempt to re-use connections for multiple file transfers, so that
  69. getting many files from the same server will not do multiple connects /
  70. handshakes. This improves speed. Of course this is only done on files
  71. specified on a single command line and cannot be used between separate curl
  72. invokes.
  73. .SH "PROGRESS METER"
  74. curl normally displays a progress meter during operations, indicating the
  75. amount of transferred data, transfer speeds and estimated time left, etc.
  76. curl displays this data to the terminal by default, so if you invoke curl to
  77. do an operation and it is about to write data to the terminal, it
  78. \fIdisables\fP the progress meter as otherwise it would mess up the output
  79. mixing progress meter and response data.
  80. If you want a progress meter for HTTP POST or PUT requests, you need to
  81. redirect the response output to a file, using shell redirect (>), -o [file] or
  82. similar.
  83. It is not the same case for FTP upload as that operation does not spit out
  84. any response data to the terminal.
  85. If you prefer a progress "bar" instead of the regular meter, \fI-#\fP is your
  86. friend.
  87. .SH OPTIONS
  88. Options start with one or two dashes. Many of the options require an addition
  89. value next to it.
  90. The short "single-dash" form of the options, -d for example, may be used with
  91. or without a space between it and its value, although a space is a recommended
  92. separator. The long "double-dash" form, --data for example, requires a space
  93. between it and its value.
  94. Short version options that don't need any additional values can be used
  95. immediately next to each other, like for example you can specify all the
  96. options -O, -L and -v at once as -OLv.
  97. In general, all boolean options are enabled with --\fBoption\fP and yet again
  98. disabled with --\fBno-\fPoption. That is, you use the exact same option name
  99. but prefix it with "no-". However, in this list we mostly only list and show
  100. the --option version of them. (This concept with --no options was added in
  101. 7.19.0. Previously most options were toggled on/off on repeated use of the
  102. same command line option.)
  103. .IP "-#, --progress-bar"
  104. Make curl display progress as a simple progress bar instead of the standard,
  105. more informational, meter.
  106. .IP "-0, --http1.0"
  107. (HTTP) Tells curl to use HTTP version 1.0 instead of using its internally
  108. preferred: HTTP 1.1.
  109. .IP "--http1.1"
  110. (HTTP) Tells curl to use HTTP version 1.1. This is the internal default
  111. version. (Added in 7.33.0)
  112. .IP "--http2"
  113. (HTTP) Tells curl to issue its requests using HTTP 2. This requires that the
  114. underlying libcurl was built to support it. (Added in 7.33.0)
  115. .IP "-1, --tlsv1"
  116. (SSL)
  117. Forces curl to use TLS version 1 when negotiating with a remote TLS server.
  118. .IP "-2, --sslv2"
  119. (SSL)
  120. Forces curl to use SSL version 2 when negotiating with a remote SSL server.
  121. .IP "-3, --sslv3"
  122. (SSL)
  123. Forces curl to use SSL version 3 when negotiating with a remote SSL server.
  124. .IP "-4, --ipv4"
  125. If curl is capable of resolving an address to multiple IP versions (which it
  126. is if it is IPv6-capable), this option tells curl to resolve names to IPv4
  127. addresses only.
  128. .IP "-6, --ipv6"
  129. If curl is capable of resolving an address to multiple IP versions (which it
  130. is if it is IPv6-capable), this option tells curl to resolve names to IPv6
  131. addresses only.
  132. .IP "-a, --append"
  133. (FTP/SFTP) When used in an upload, this will tell curl to append to the target
  134. file instead of overwriting it. If the file doesn't exist, it will be created.
  135. Note that this flag is ignored by some SSH servers (including OpenSSH).
  136. .IP "-A, --user-agent <agent string>"
  137. (HTTP) Specify the User-Agent string to send to the HTTP server. Some badly
  138. done CGIs fail if this field isn't set to "Mozilla/4.0". To encode blanks in
  139. the string, surround the string with single quote marks. This can also be set
  140. with the \fI-H, --header\fP option of course.
  141. If this option is used several times, the last one will be used.
  142. .IP "--anyauth"
  143. (HTTP) Tells curl to figure out authentication method by itself, and use the
  144. most secure one the remote site claims to support. This is done by first
  145. doing a request and checking the response-headers, thus possibly inducing an
  146. extra network round-trip. This is used instead of setting a specific
  147. authentication method, which you can do with \fI--basic\fP, \fI--digest\fP,
  148. \fI--ntlm\fP, and \fI--negotiate\fP.
  149. Note that using --anyauth is not recommended if you do uploads from stdin,
  150. since it may require data to be sent twice and then the client must be able to
  151. rewind. If the need should arise when uploading from stdin, the upload
  152. operation will fail.
  153. .IP "-b, --cookie <name=data>"
  154. (HTTP)
  155. Pass the data to the HTTP server as a cookie. It is supposedly the
  156. data previously received from the server in a "Set-Cookie:" line.
  157. The data should be in the format "NAME1=VALUE1; NAME2=VALUE2".
  158. If no '=' symbol is used in the line, it is treated as a filename to use to
  159. read previously stored cookie lines from, which should be used in this session
  160. if they match. Using this method also activates the "cookie parser" which will
  161. make curl record incoming cookies too, which may be handy if you're using this
  162. in combination with the \fI-L, --location\fP option. The file format of the
  163. file to read cookies from should be plain HTTP headers or the Netscape/Mozilla
  164. cookie file format.
  165. \fBNOTE\fP that the file specified with \fI-b, --cookie\fP is only used as
  166. input. No cookies will be stored in the file. To store cookies, use the
  167. \fI-c, --cookie-jar\fP option or you could even save the HTTP headers to a file
  168. using \fI-D, --dump-header\fP!
  169. If this option is used several times, the last one will be used.
  170. .IP "-B, --use-ascii"
  171. (FTP/LDAP) Enable ASCII transfer. For FTP, this can also be
  172. enforced by using an URL that ends with ";type=A". This option causes data
  173. sent to stdout to be in text mode for win32 systems.
  174. .IP "--basic"
  175. (HTTP) Tells curl to use HTTP Basic authentication. This is the default and
  176. this option is usually pointless, unless you use it to override a previously
  177. set option that sets a different authentication method (such as \fI--ntlm\fP,
  178. \fI--digest\fP, or \fI--negotiate\fP).
  179. .IP "-c, --cookie-jar <file name>"
  180. (HTTP) Specify to which file you want curl to write all cookies after a
  181. completed operation. Curl writes all cookies previously read from a specified
  182. file as well as all cookies received from remote server(s). If no cookies are
  183. known, no file will be written. The file will be written using the Netscape
  184. cookie file format. If you set the file name to a single dash, "-", the
  185. cookies will be written to stdout.
  186. This command line option will activate the cookie engine that makes curl
  187. record and use cookies. Another way to activate it is to use the \fI-b,
  188. --cookie\fP option.
  189. If the cookie jar can't be created or written to, the whole curl operation
  190. won't fail or even report an error clearly. Using -v will get a warning
  191. displayed, but that is the only visible feedback you get about this possibly
  192. lethal situation.
  193. If this option is used several times, the last specified file name will be
  194. used.
  195. .IP "-C, --continue-at <offset>"
  196. Continue/Resume a previous file transfer at the given offset. The given offset
  197. is the exact number of bytes that will be skipped, counting from the beginning
  198. of the source file before it is transferred to the destination. If used with
  199. uploads, the FTP server command SIZE will not be used by curl.
  200. Use "-C -" to tell curl to automatically find out where/how to resume the
  201. transfer. It then uses the given output/input files to figure that out.
  202. If this option is used several times, the last one will be used.
  203. .IP "--ciphers <list of ciphers>"
  204. (SSL) Specifies which ciphers to use in the connection. The list of ciphers
  205. must specify valid ciphers. Read up on SSL cipher list details on this URL:
  206. \fIhttp://www.openssl.org/docs/apps/ciphers.html\fP
  207. NSS ciphers are done differently than OpenSSL and GnuTLS. The full list of NSS
  208. ciphers is in the NSSCipherSuite entry at this URL:
  209. \fIhttp://git.fedorahosted.org/cgit/mod_nss.git/plain/docs/mod_nss.html#Directives\fP
  210. If this option is used several times, the last one will be used.
  211. .IP "--compressed"
  212. (HTTP) Request a compressed response using one of the algorithms curl
  213. supports, and save the uncompressed document. If this option is used and the
  214. server sends an unsupported encoding, curl will report an error.
  215. .IP "--connect-timeout <seconds>"
  216. Maximum time in seconds that you allow the connection to the server to take.
  217. This only limits the connection phase, once curl has connected this option is
  218. of no more use. Since 7.32.0, this option accepts decimal values, but the
  219. actual timeout will decrease in accuracy as the specified timeout increases in
  220. decimal precision. See also the \fI-m, --max-time\fP option.
  221. If this option is used several times, the last one will be used.
  222. .IP "--create-dirs"
  223. When used in conjunction with the \fI-o\fP option, curl will create the
  224. necessary local directory hierarchy as needed. This option creates the dirs
  225. mentioned with the \fI-o\fP option, nothing else. If the \fI-o\fP file name
  226. uses no dir or if the dirs it mentions already exist, no dir will be created.
  227. To create remote directories when using FTP or SFTP, try
  228. \fI--ftp-create-dirs\fP.
  229. .IP "--crlf"
  230. (FTP) Convert LF to CRLF in upload. Useful for MVS (OS/390).
  231. .IP "--crlfile <file>"
  232. (HTTPS/FTPS) Provide a file using PEM format with a Certificate Revocation
  233. List that may specify peer certificates that are to be considered revoked.
  234. If this option is used several times, the last one will be used.
  235. (Added in 7.19.7)
  236. .IP "-d, --data <data>"
  237. (HTTP) Sends the specified data in a POST request to the HTTP server, in the
  238. same way that a browser does when a user has filled in an HTML form and
  239. presses the submit button. This will cause curl to pass the data to the server
  240. using the content-type application/x-www-form-urlencoded. Compare to
  241. \fI-F, --form\fP.
  242. \fI-d, --data\fP is the same as \fI--data-ascii\fP. To post data purely binary,
  243. you should instead use the \fI--data-binary\fP option. To URL-encode the value
  244. of a form field you may use \fI--data-urlencode\fP.
  245. If any of these options is used more than once on the same command line, the
  246. data pieces specified will be merged together with a separating
  247. &-symbol. Thus, using '-d name=daniel -d skill=lousy' would generate a post
  248. chunk that looks like \&'name=daniel&skill=lousy'.
  249. If you start the data with the letter @, the rest should be a file name to
  250. read the data from, or - if you want curl to read the data from
  251. stdin. Multiple files can also be specified. Posting data from a file
  252. named 'foobar' would thus be done with \fI--data\fP @foobar. When --data is
  253. told to read from a file like that, carriage returns and newlines will be
  254. stripped out.
  255. .IP "-D, --dump-header <file>"
  256. Write the protocol headers to the specified file.
  257. This option is handy to use when you want to store the headers that an HTTP
  258. site sends to you. Cookies from the headers could then be read in a second
  259. curl invocation by using the \fI-b, --cookie\fP option! The
  260. \fI-c, --cookie-jar\fP option is however a better way to store cookies.
  261. When used in FTP, the FTP server response lines are considered being "headers"
  262. and thus are saved there.
  263. If this option is used several times, the last one will be used.
  264. .IP "--data-ascii <data>"
  265. See \fI-d, --data\fP.
  266. .IP "--data-binary <data>"
  267. (HTTP) This posts data exactly as specified with no extra processing
  268. whatsoever.
  269. If you start the data with the letter @, the rest should be a filename. Data
  270. is posted in a similar manner as \fI--data-ascii\fP does, except that newlines
  271. and carriage returns are preserved and conversions are never done.
  272. If this option is used several times, the ones following the first will append
  273. data as described in \fI-d, --data\fP.
  274. .IP "--data-urlencode <data>"
  275. (HTTP) This posts data, similar to the other --data options with the exception
  276. that this performs URL-encoding. (Added in 7.18.0)
  277. To be CGI-compliant, the <data> part should begin with a \fIname\fP followed
  278. by a separator and a content specification. The <data> part can be passed to
  279. curl using one of the following syntaxes:
  280. .RS
  281. .IP "content"
  282. This will make curl URL-encode the content and pass that on. Just be careful
  283. so that the content doesn't contain any = or @ symbols, as that will then make
  284. the syntax match one of the other cases below!
  285. .IP "=content"
  286. This will make curl URL-encode the content and pass that on. The preceding =
  287. symbol is not included in the data.
  288. .IP "name=content"
  289. This will make curl URL-encode the content part and pass that on. Note that
  290. the name part is expected to be URL-encoded already.
  291. .IP "@filename"
  292. This will make curl load data from the given file (including any newlines),
  293. URL-encode that data and pass it on in the POST.
  294. .IP "name@filename"
  295. This will make curl load data from the given file (including any newlines),
  296. URL-encode that data and pass it on in the POST. The name part gets an equal
  297. sign appended, resulting in \fIname=urlencoded-file-content\fP. Note that the
  298. name is expected to be URL-encoded already.
  299. .RE
  300. .IP "--delegation LEVEL"
  301. Set \fILEVEL\fP to tell the server what it is allowed to delegate when it
  302. comes to user credentials. Used with GSS/kerberos.
  303. .RS
  304. .IP "none"
  305. Don't allow any delegation.
  306. .IP "policy"
  307. Delegates if and only if the OK-AS-DELEGATE flag is set in the Kerberos
  308. service ticket, which is a matter of realm policy.
  309. .IP "always"
  310. Unconditionally allow the server to delegate.
  311. .RE
  312. .IP "--digest"
  313. (HTTP) Enables HTTP Digest authentication. This is an authentication scheme
  314. that prevents the password from being sent over the wire in clear text. Use
  315. this in combination with the normal \fI-u, --user\fP option to set user name
  316. and password. See also \fI--ntlm\fP, \fI--negotiate\fP and \fI--anyauth\fP for
  317. related options.
  318. If this option is used several times, only the first one is used.
  319. .IP "--disable-eprt"
  320. (FTP) Tell curl to disable the use of the EPRT and LPRT commands when doing
  321. active FTP transfers. Curl will normally always first attempt to use EPRT,
  322. then LPRT before using PORT, but with this option, it will use PORT right
  323. away. EPRT and LPRT are extensions to the original FTP protocol, and may not
  324. work on all servers, but they enable more functionality in a better way than
  325. the traditional PORT command.
  326. \fB--eprt\fP can be used to explicitly enable EPRT again and \fB--no-eprt\fP
  327. is an alias for \fB--disable-eprt\fP.
  328. Disabling EPRT only changes the active behavior. If you want to switch to
  329. passive mode you need to not use \fI-P, --ftp-port\fP or force it with
  330. \fI--ftp-pasv\fP.
  331. .IP "--disable-epsv"
  332. (FTP) Tell curl to disable the use of the EPSV command when doing passive FTP
  333. transfers. Curl will normally always first attempt to use EPSV before PASV,
  334. but with this option, it will not try using EPSV.
  335. \fB--epsv\fP can be used to explicitly enable EPSV again and \fB--no-epsv\fP
  336. is an alias for \fB--disable-epsv\fP.
  337. Disabling EPSV only changes the passive behavior. If you want to switch to
  338. active mode you need to use \fI-P, --ftp-port\fP.
  339. .IP "--dns-interface <interface>"
  340. Tell curl to send outgoing DNS requests through <interface>. This option
  341. is a counterpart to \fI--interface\fP (which does not affect DNS). The
  342. supplied string must be an interface name (not an address).
  343. This option requires that libcurl was built with a resolver backend that
  344. supports this operation. The c-ares backend is the only such one. (Added in
  345. 7.33.0)
  346. .IP "--dns-ipv4-addr <ip-address>"
  347. Tell curl to bind to <ip-address> when making IPv4 DNS requests, so that
  348. the DNS requests originate from this address. The argument should be a
  349. single IPv4 address.
  350. This option requires that libcurl was built with a resolver backend that
  351. supports this operation. The c-ares backend is the only such one. (Added in
  352. 7.33.0)
  353. .IP "--dns-ipv6-addr <ip-address>"
  354. Tell curl to bind to <ip-address> when making IPv6 DNS requests, so that
  355. the DNS requests originate from this address. The argument should be a
  356. single IPv6 address.
  357. This option requires that libcurl was built with a resolver backend that
  358. supports this operation. The c-ares backend is the only such one. (Added in
  359. 7.33.0)
  360. .IP "--dns-servers <ip-address,ip-address>"
  361. Set the list of DNS servers to be used instead of the system default.
  362. The list of IP addresses should be separated with commas. Port numbers
  363. may also optionally be given as \fI:<port-number>\fP after each IP
  364. address.
  365. This option requires that libcurl was built with a resolver backend that
  366. supports this operation. The c-ares backend is the only such one. (Added in
  367. 7.33.0)
  368. .IP "-e, --referer <URL>"
  369. (HTTP) Sends the "Referer Page" information to the HTTP server. This can also
  370. be set with the \fI-H, --header\fP flag of course. When used with
  371. \fI-L, --location\fP you can append ";auto" to the --referer URL to make curl
  372. automatically set the previous URL when it follows a Location: header. The
  373. \&";auto" string can be used alone, even if you don't set an initial --referer.
  374. If this option is used several times, the last one will be used.
  375. .IP "-E, --cert <certificate[:password]>"
  376. (SSL) Tells curl to use the specified client certificate file when getting a
  377. file with HTTPS, FTPS or another SSL-based protocol. The certificate must be
  378. in PKCS#12 format if using Secure Transport, or PEM format if using any other
  379. engine. If the optional password isn't specified, it will be queried
  380. for on the terminal. Note that this option assumes a \&"certificate" file that
  381. is the private key and the private certificate concatenated! See \fI--cert\fP
  382. and \fI--key\fP to specify them independently.
  383. If curl is built against the NSS SSL library then this option can tell
  384. curl the nickname of the certificate to use within the NSS database defined
  385. by the environment variable SSL_DIR (or by default /etc/pki/nssdb). If the
  386. NSS PEM PKCS#11 module (libnsspem.so) is available then PEM files may be
  387. loaded. If you want to use a file from the current directory, please precede
  388. it with "./" prefix, in order to avoid confusion with a nickname. If the
  389. nickname contains ":", it needs to be preceded by "\\" so that it is not
  390. recognized as password delimiter. If the nickname contains "\\", it needs to
  391. be escaped as "\\\\" so that it is not recognized as an escape character.
  392. (iOS and Mac OS X only) If curl is built against Secure Transport, then the
  393. certificate string can either be the name of a certificate/private key in the
  394. system or user keychain, or the path to a PKCS#12-encoded certificate and
  395. private key. If you want to use a file from the current directory, please
  396. precede it with "./" prefix, in order to avoid confusion with a nickname.
  397. If this option is used several times, the last one will be used.
  398. .IP "--engine <name>"
  399. Select the OpenSSL crypto engine to use for cipher
  400. operations. Use \fI--engine list\fP to print a list of build-time supported
  401. engines. Note that not all (or none) of the engines may be available at
  402. run-time.
  403. .IP "--environment"
  404. (RISC OS ONLY) Sets a range of environment variables, using the names the
  405. \fI-w\fP option supports, to allow easier extraction of useful information
  406. after having run curl.
  407. .IP "--egd-file <file>"
  408. (SSL) Specify the path name to the Entropy Gathering Daemon socket. The socket
  409. is used to seed the random engine for SSL connections. See also the
  410. \fI--random-file\fP option.
  411. .IP "--cert-type <type>"
  412. (SSL) Tells curl what certificate type the provided certificate is in. PEM,
  413. DER and ENG are recognized types. If not specified, PEM is assumed.
  414. If this option is used several times, the last one will be used.
  415. .IP "--cacert <CA certificate>"
  416. (SSL) Tells curl to use the specified certificate file to verify the peer. The
  417. file may contain multiple CA certificates. The certificate(s) must be in PEM
  418. format. Normally curl is built to use a default file for this, so this option
  419. is typically used to alter that default file.
  420. curl recognizes the environment variable named 'CURL_CA_BUNDLE' if it is
  421. set, and uses the given path as a path to a CA cert bundle. This option
  422. overrides that variable.
  423. The windows version of curl will automatically look for a CA certs file named
  424. \'curl-ca-bundle.crt\', either in the same directory as curl.exe, or in the
  425. Current Working Directory, or in any folder along your PATH.
  426. If curl is built against the NSS SSL library, the NSS PEM PKCS#11 module
  427. (libnsspem.so) needs to be available for this option to work properly.
  428. If this option is used several times, the last one will be used.
  429. .IP "--capath <CA certificate directory>"
  430. (SSL) Tells curl to use the specified certificate directory to verify the
  431. peer. Multiple paths can be provided by separating them with ":" (e.g.
  432. \&"path1:path2:path3"). The certificates must be in PEM format, and if curl is
  433. built against OpenSSL, the directory must have been processed using the
  434. c_rehash utility supplied with OpenSSL. Using \fI--capath\fP can allow
  435. OpenSSL-powered curl to make SSL-connections much more efficiently than using
  436. \fI--cacert\fP if the \fI--cacert\fP file contains many CA certificates.
  437. If this option is set, the default capath value will be ignored, and if it is
  438. used several times, the last one will be used.
  439. .IP "-f, --fail"
  440. (HTTP) Fail silently (no output at all) on server errors. This is mostly done
  441. to better enable scripts etc to better deal with failed attempts. In
  442. normal cases when an HTTP server fails to deliver a document, it returns an
  443. HTML document stating so (which often also describes why and more). This flag
  444. will prevent curl from outputting that and return error 22.
  445. This method is not fail-safe and there are occasions where non-successful
  446. response codes will slip through, especially when authentication is involved
  447. (response codes 401 and 407).
  448. .IP "-F, --form <name=content>"
  449. (HTTP) This lets curl emulate a filled-in form in which a user has pressed the
  450. submit button. This causes curl to POST data using the Content-Type
  451. multipart/form-data according to RFC 2388. This enables uploading of binary
  452. files etc. To force the 'content' part to be a file, prefix the file name
  453. with an @ sign. To just get the content part from a file, prefix the file name
  454. with the symbol <. The difference between @ and < is then that @ makes a file
  455. get attached in the post as a file upload, while the < makes a text field and
  456. just get the contents for that text field from a file.
  457. Example, to send your password file to the server, where
  458. \&'password' is the name of the form-field to which /etc/passwd will be the
  459. input:
  460. \fBcurl\fP -F password=@/etc/passwd www.mypasswords.com
  461. To read content from stdin instead of a file, use - as the filename. This goes
  462. for both @ and < constructs.
  463. You can also tell curl what Content-Type to use by using 'type=', in a manner
  464. similar to:
  465. \fBcurl\fP -F "web=@index.html;type=text/html" url.com
  466. or
  467. \fBcurl\fP -F "name=daniel;type=text/foo" url.com
  468. You can also explicitly change the name field of a file upload part by setting
  469. filename=, like this:
  470. \fBcurl\fP -F "file=@localfile;filename=nameinpost" url.com
  471. If filename/path contains ',' or ';', it must be quoted by double-quotes like:
  472. \fBcurl\fP -F "file=@\\"localfile\\";filename=\\"nameinpost\\"" url.com
  473. or
  474. \fBcurl\fP -F 'file=@"localfile";filename="nameinpost"' url.com
  475. Note that if a filename/path is quoted by double-quotes, any double-quote
  476. or backslash within the filename must be escaped by backslash.
  477. See further examples and details in the MANUAL.
  478. This option can be used multiple times.
  479. .IP "--ftp-account [data]"
  480. (FTP) When an FTP server asks for "account data" after user name and password
  481. has been provided, this data is sent off using the ACCT command. (Added in
  482. 7.13.0)
  483. If this option is used several times, the last one will be used.
  484. .IP "--ftp-alternative-to-user <command>"
  485. (FTP) If authenticating with the USER and PASS commands fails, send this
  486. command. When connecting to Tumbleweed's Secure Transport server over FTPS
  487. using a client certificate, using "SITE AUTH" will tell the server to retrieve
  488. the username from the certificate. (Added in 7.15.5)
  489. .IP "--ftp-create-dirs"
  490. (FTP/SFTP) When an FTP or SFTP URL/operation uses a path that doesn't
  491. currently exist on the server, the standard behavior of curl is to
  492. fail. Using this option, curl will instead attempt to create missing
  493. directories.
  494. .IP "--ftp-method [method]"
  495. (FTP) Control what method curl should use to reach a file on an FTP(S)
  496. server. The method argument should be one of the following alternatives:
  497. .RS
  498. .IP multicwd
  499. curl does a single CWD operation for each path part in the given URL. For deep
  500. hierarchies this means very many commands. This is how RFC 1738 says it should
  501. be done. This is the default but the slowest behavior.
  502. .IP nocwd
  503. curl does no CWD at all. curl will do SIZE, RETR, STOR etc and give a full
  504. path to the server for all these commands. This is the fastest behavior.
  505. .IP singlecwd
  506. curl does one CWD with the full target directory and then operates on the file
  507. \&"normally" (like in the multicwd case). This is somewhat more standards
  508. compliant than 'nocwd' but without the full penalty of 'multicwd'.
  509. .RE
  510. (Added in 7.15.1)
  511. .IP "--ftp-pasv"
  512. (FTP) Use passive mode for the data connection. Passive is the internal default
  513. behavior, but using this option can be used to override a previous
  514. \fI-P/-ftp-port\fP option. (Added in 7.11.0)
  515. If this option is used several times, only the first one is used. Undoing an
  516. enforced passive really isn't doable but you must then instead enforce the
  517. correct \fI-P, --ftp-port\fP again.
  518. Passive mode means that curl will try the EPSV command first and then PASV,
  519. unless \fI--disable-epsv\fP is used.
  520. .IP "--ftp-skip-pasv-ip"
  521. (FTP) Tell curl to not use the IP address the server suggests in its response
  522. to curl's PASV command when curl connects the data connection. Instead curl
  523. will re-use the same IP address it already uses for the control
  524. connection. (Added in 7.14.2)
  525. This option has no effect if PORT, EPRT or EPSV is used instead of PASV.
  526. .IP "--ftp-pret"
  527. (FTP) Tell curl to send a PRET command before PASV (and EPSV). Certain
  528. FTP servers, mainly drftpd, require this non-standard command for
  529. directory listings as well as up and downloads in PASV mode.
  530. (Added in 7.20.x)
  531. .IP "--ftp-ssl-ccc"
  532. (FTP) Use CCC (Clear Command Channel)
  533. Shuts down the SSL/TLS layer after authenticating. The rest of the
  534. control channel communication will be unencrypted. This allows
  535. NAT routers to follow the FTP transaction. The default mode is
  536. passive. See \fI--ftp-ssl-ccc-mode\fP for other modes.
  537. (Added in 7.16.1)
  538. .IP "--ftp-ssl-ccc-mode [active/passive]"
  539. (FTP) Use CCC (Clear Command Channel)
  540. Sets the CCC mode. The passive mode will not initiate the shutdown, but
  541. instead wait for the server to do it, and will not reply to the
  542. shutdown from the server. The active mode initiates the shutdown and
  543. waits for a reply from the server.
  544. (Added in 7.16.2)
  545. .IP "--ftp-ssl-control"
  546. (FTP) Require SSL/TLS for the FTP login, clear for transfer. Allows secure
  547. authentication, but non-encrypted data transfers for efficiency. Fails the
  548. transfer if the server doesn't support SSL/TLS. (Added in 7.16.0)
  549. that can still be used but will be removed in a future version.
  550. .IP "--form-string <name=string>"
  551. (HTTP) Similar to \fI--form\fP except that the value string for the named
  552. parameter is used literally. Leading \&'@' and \&'<' characters, and the
  553. \&';type=' string in the value have no special meaning. Use this in preference
  554. to \fI--form\fP if there's any possibility that the string value may
  555. accidentally trigger the \&'@' or \&'<' features of \fI--form\fP.
  556. .IP "-g, --globoff"
  557. This option switches off the "URL globbing parser". When you set this option,
  558. you can specify URLs that contain the letters {}[] without having them being
  559. interpreted by curl itself. Note that these letters are not normal legal URL
  560. contents but they should be encoded according to the URI standard.
  561. .IP "-G, --get"
  562. When used, this option will make all data specified with \fI-d, --data\fP,
  563. \fI--data-binary\fP or \fI--data-urlencode\fP to be used in an HTTP GET
  564. request instead of the POST request that otherwise would be used. The data
  565. will be appended to the URL with a '?' separator.
  566. If used in combination with -I, the POST data will instead be appended to the
  567. URL with a HEAD request.
  568. If this option is used several times, only the first one is used. This is
  569. because undoing a GET doesn't make sense, but you should then instead enforce
  570. the alternative method you prefer.
  571. .IP "-H, --header <header>"
  572. (HTTP) Extra header to use when getting a web page. You may specify any number
  573. of extra headers. Note that if you should add a custom header that has the
  574. same name as one of the internal ones curl would use, your externally set
  575. header will be used instead of the internal one. This allows you to make even
  576. trickier stuff than curl would normally do. You should not replace internally
  577. set headers without knowing perfectly well what you're doing. Remove an
  578. internal header by giving a replacement without content on the right side of
  579. the colon, as in: -H \&"Host:". If you send the custom header with no-value
  580. then its header must be terminated with a semicolon, such as \-H
  581. \&"X-Custom-Header;" to send "X-Custom-Header:".
  582. curl will make sure that each header you add/replace is sent with the proper
  583. end-of-line marker, you should thus \fBnot\fP add that as a part of the header
  584. content: do not add newlines or carriage returns, they will only mess things up
  585. for you.
  586. See also the \fI-A, --user-agent\fP and \fI-e, --referer\fP options.
  587. This option can be used multiple times to add/replace/remove multiple headers.
  588. .IP "--hostpubmd5 <md5>"
  589. (SCP/SFTP) Pass a string containing 32 hexadecimal digits. The string should
  590. be the 128 bit MD5 checksum of the remote host's public key, curl will refuse
  591. the connection with the host unless the md5sums match. (Added in 7.17.1)
  592. .IP "--ignore-content-length"
  593. (HTTP)
  594. Ignore the Content-Length header. This is particularly useful for servers
  595. running Apache 1.x, which will report incorrect Content-Length for files
  596. larger than 2 gigabytes.
  597. .IP "-i, --include"
  598. (HTTP) Include the HTTP-header in the output. The HTTP-header includes things
  599. like server-name, date of the document, HTTP-version and more...
  600. .IP "-I, --head"
  601. (HTTP/FTP/FILE)
  602. Fetch the HTTP-header only! HTTP-servers feature the command HEAD
  603. which this uses to get nothing but the header of a document. When used
  604. on an FTP or FILE file, curl displays the file size and last modification
  605. time only.
  606. .IP "--interface <name>"
  607. Perform an operation using a specified interface. You can enter interface
  608. name, IP address or host name. An example could look like:
  609. curl --interface eth0:1 http://www.netscape.com/
  610. If this option is used several times, the last one will be used.
  611. .IP "-j, --junk-session-cookies"
  612. (HTTP) When curl is told to read cookies from a given file, this option will
  613. make it discard all "session cookies". This will basically have the same effect
  614. as if a new session is started. Typical browsers always discard session
  615. cookies when they're closed down.
  616. .IP "-J, --remote-header-name"
  617. (HTTP) This option tells the \fI-O, --remote-name\fP option to use the
  618. server-specified Content-Disposition filename instead of extracting a filename
  619. from the URL.
  620. There's no attempt to decode %-sequences (yet) in the provided file name, so
  621. this option may provide you with rather unexpected file names.
  622. .IP "-k, --insecure"
  623. (SSL) This option explicitly allows curl to perform "insecure" SSL connections
  624. and transfers. All SSL connections are attempted to be made secure by using
  625. the CA certificate bundle installed by default. This makes all connections
  626. considered "insecure" fail unless \fI-k, --insecure\fP is used.
  627. See this online resource for further details:
  628. \fBhttp://curl.haxx.se/docs/sslcerts.html\fP
  629. .IP "-K, --config <config file>"
  630. Specify which config file to read curl arguments from. The config file is a
  631. text file in which command line arguments can be written which then will be
  632. used as if they were written on the actual command line.
  633. Options and their parameters must be specified on the same config file line,
  634. separated by whitespace, colon, or the equals sign. Long option names can
  635. optionally be given in the config file without the initial double dashes and
  636. if so, the colon or equals characters can be used as separators. If the option
  637. is specified with one or two dashes, there can be no colon or equals character
  638. between the option and its parameter.
  639. If the parameter is to contain whitespace, the parameter must be enclosed
  640. within quotes. Within double quotes, the following escape sequences are
  641. available: \\\\, \\", \\t, \\n, \\r and \\v. A backslash preceding any other
  642. letter is ignored. If the first column of a config line is a '#' character,
  643. the rest of the line will be treated as a comment. Only write one option per
  644. physical line in the config file.
  645. Specify the filename to -K, --config as '-' to make curl read the file from
  646. stdin.
  647. Note that to be able to specify a URL in the config file, you need to specify
  648. it using the \fI--url\fP option, and not by simply writing the URL on its own
  649. line. So, it could look similar to this:
  650. url = "http://curl.haxx.se/docs/"
  651. When curl is invoked, it always (unless \fI-q\fP is used) checks for a default
  652. config file and uses it if found. The default config file is checked for in
  653. the following places in this order:
  654. 1) curl tries to find the "home dir": It first checks for the CURL_HOME and
  655. then the HOME environment variables. Failing that, it uses getpwuid() on
  656. UNIX-like systems (which returns the home dir given the current user in your
  657. system). On Windows, it then checks for the APPDATA variable, or as a last
  658. resort the '%USERPROFILE%\\Application Data'.
  659. 2) On windows, if there is no _curlrc file in the home dir, it checks for one
  660. in the same dir the curl executable is placed. On UNIX-like systems, it will
  661. simply try to load .curlrc from the determined home dir.
  662. .nf
  663. # --- Example file ---
  664. # this is a comment
  665. url = "curl.haxx.se"
  666. output = "curlhere.html"
  667. user-agent = "superagent/1.0"
  668. # and fetch another URL too
  669. url = "curl.haxx.se/docs/manpage.html"
  670. -O
  671. referer = "http://nowhereatall.com/"
  672. # --- End of example file ---
  673. .fi
  674. This option can be used multiple times to load multiple config files.
  675. .IP "--keepalive-time <seconds>"
  676. This option sets the time a connection needs to remain idle before sending
  677. keepalive probes and the time between individual keepalive probes. It is
  678. currently effective on operating systems offering the TCP_KEEPIDLE and
  679. TCP_KEEPINTVL socket options (meaning Linux, recent AIX, HP-UX and more). This
  680. option has no effect if \fI--no-keepalive\fP is used. (Added in 7.18.0)
  681. If this option is used several times, the last one will be used. If
  682. unspecified, the option defaults to 60 seconds.
  683. .IP "--key <key>"
  684. (SSL/SSH) Private key file name. Allows you to provide your private key in this
  685. separate file.
  686. If this option is used several times, the last one will be used.
  687. .IP "--key-type <type>"
  688. (SSL) Private key file type. Specify which type your \fI--key\fP provided
  689. private key is. DER, PEM, and ENG are supported. If not specified, PEM is
  690. assumed.
  691. If this option is used several times, the last one will be used.
  692. .IP "--krb <level>"
  693. (FTP) Enable Kerberos authentication and use. The level must be entered and
  694. should be one of 'clear', 'safe', 'confidential', or 'private'. Should you use
  695. a level that is not one of these, 'private' will instead be used.
  696. This option requires a library built with kerberos4 or GSSAPI
  697. (GSS-Negotiate) support. This is not very common. Use \fI-V, --version\fP to
  698. see if your curl supports it.
  699. If this option is used several times, the last one will be used.
  700. .IP "-l, --list-only"
  701. (FTP)
  702. When listing an FTP directory, this switch forces a name-only view. This is
  703. especially useful if the user wants to machine-parse the contents of an FTP
  704. directory since the normal directory view doesn't use a standard look or
  705. format. When used like this, the option causes a NLST command to be sent to
  706. the server instead of LIST.
  707. Note: Some FTP servers list only files in their response to NLST; they do not
  708. include sub-directories and symbolic links.
  709. (POP3)
  710. When retrieving a specific email from POP3, this switch forces a LIST command
  711. to be performed instead of RETR. This is particularly useful if the user wants
  712. to see if a specific message id exists on the server and what size it is.
  713. Note: When combined with \fI-X, --request <command>\fP, this option can be used
  714. to send an UIDL command instead, so the user may use the email's unique
  715. identifier rather than it's message id to make the request. (Added in 7.21.5)
  716. .IP "-L, --location"
  717. (HTTP/HTTPS) If the server reports that the requested page has moved to a
  718. different location (indicated with a Location: header and a 3XX response code),
  719. this option will make curl redo the request on the new place. If used together
  720. with \fI-i, --include\fP or \fI-I, --head\fP, headers from all requested pages
  721. will be shown. When authentication is used, curl only sends its credentials to
  722. the initial host. If a redirect takes curl to a different host, it won't be
  723. able to intercept the user+password. See also \fI--location-trusted\fP on how
  724. to change this. You can limit the amount of redirects to follow by using the
  725. \fI--max-redirs\fP option.
  726. When curl follows a redirect and the request is not a plain GET (for example
  727. POST or PUT), it will do the following request with a GET if the HTTP response
  728. was 301, 302, or 303. If the response code was any other 3xx code, curl will
  729. re-send the following request using the same unmodified method.
  730. .IP "--libcurl <file>"
  731. Append this option to any ordinary curl command line, and you will get a
  732. libcurl-using C source code written to the file that does the equivalent
  733. of what your command-line operation does!
  734. If this option is used several times, the last given file name will be
  735. used. (Added in 7.16.1)
  736. .IP "--limit-rate <speed>"
  737. Specify the maximum transfer rate you want curl to use. This feature is useful
  738. if you have a limited pipe and you'd like your transfer not to use your entire
  739. bandwidth.
  740. The given speed is measured in bytes/second, unless a suffix is appended.
  741. Appending 'k' or 'K' will count the number as kilobytes, 'm' or M' makes it
  742. megabytes, while 'g' or 'G' makes it gigabytes. Examples: 200K, 3m and 1G.
  743. The given rate is the average speed counted during the entire transfer. It
  744. means that curl might use higher transfer speeds in short bursts, but over
  745. time it uses no more than the given rate.
  746. If you also use the \fI-Y, --speed-limit\fP option, that option will take
  747. precedence and might cripple the rate-limiting slightly, to help keeping the
  748. speed-limit logic working.
  749. If this option is used several times, the last one will be used.
  750. .IP "--local-port <num>[-num]"
  751. Set a preferred number or range of local port numbers to use for the
  752. connection(s). Note that port numbers by nature are a scarce resource that
  753. will be busy at times so setting this range to something too narrow might
  754. cause unnecessary connection setup failures. (Added in 7.15.2)
  755. .IP "--location-trusted"
  756. (HTTP/HTTPS) Like \fI-L, --location\fP, but will allow sending the name +
  757. password to all hosts that the site may redirect to. This may or may not
  758. introduce a security breach if the site redirects you to a site to which
  759. you'll send your authentication info (which is plaintext in the case of HTTP
  760. Basic authentication).
  761. .IP "-m, --max-time <seconds>"
  762. Maximum time in seconds that you allow the whole operation to take. This is
  763. useful for preventing your batch jobs from hanging for hours due to slow
  764. networks or links going down. Since 7.32.0, this option accepts decimal
  765. values, but the actual timeout will decrease in accuracy as the specified
  766. timeout increases in decimal precision. See also the \fI--connect-timeout\fP
  767. option.
  768. If this option is used several times, the last one will be used.
  769. .IP "--mail-auth <address>"
  770. (SMTP) Specify a single address. This will be used to specify the
  771. authentication address (identity) of a submitted message that is being relayed
  772. to another server.
  773. (Added in 7.25.0)
  774. .IP "--mail-from <address>"
  775. (SMTP) Specify a single address that the given mail should get sent from.
  776. (Added in 7.20.0)
  777. .IP "--max-filesize <bytes>"
  778. Specify the maximum size (in bytes) of a file to download. If the file
  779. requested is larger than this value, the transfer will not start and curl will
  780. return with exit code 63.
  781. \fBNOTE:\fP The file size is not always known prior to download, and for such
  782. files this option has no effect even if the file transfer ends up being larger
  783. than this given limit. This concerns both FTP and HTTP transfers.
  784. .IP "--mail-rcpt <address>"
  785. (SMTP) Specify a single address, user name or mailing list name.
  786. When performing a mail transfer, the recipient should specify a valid email
  787. address to send the mail to. (Added in 7.20.0)
  788. When performing an address verification (VRFY command), the recipient should be
  789. specified as the user name or user name and domain (as per Section 3.5 of
  790. RFC5321). (Added in 7.34.0)
  791. When performing a mailing list expand (EXPN command), the recipient should be
  792. specified using the mailing list name, such as "Friends" or "London-Office".
  793. (Added in 7.34.0)
  794. .IP "--max-redirs <num>"
  795. Set maximum number of redirection-followings allowed. If \fI-L, --location\fP
  796. is used, this option can be used to prevent curl from following redirections
  797. \&"in absurdum". By default, the limit is set to 50 redirections. Set this
  798. option to -1 to make it limitless.
  799. If this option is used several times, the last one will be used.
  800. .IP "--metalink"
  801. This option can tell curl to parse and process a given URI as Metalink file
  802. (both version 3 and 4 (RFC 5854) are supported) and make use of the mirrors
  803. listed within for failover if there are errors (such as the file or server not
  804. being available). It will also verify the hash of the file after the download
  805. completes. The Metalink file itself is downloaded and processed in memory and
  806. not stored in the local file system.
  807. Example to use a remote Metalink file:
  808. \fBcurl\fP --metalink http://www.example.com/example.metalink
  809. To use a Metalink file in the local file system, use FILE protocol
  810. (file://):
  811. \fBcurl\fP --metalink file://example.metalink
  812. Please note that if FILE protocol is disabled, there is no way to use
  813. a local Metalink file at the time of this writing. Also note that if
  814. \fI--metalink\fP and \fI--include\fP are used together, \fI--include\fP will be
  815. ignored. This is because including headers in the response will break
  816. Metalink parser and if the headers are included in the file described
  817. in Metalink file, hash check will fail.
  818. (Added in 7.27.0, if built against the libmetalink library.)
  819. .IP "-n, --netrc"
  820. Makes curl scan the \fI.netrc\fP (\fI_netrc\fP on Windows) file in the user's
  821. home directory for login name and password. This is typically used for FTP on
  822. UNIX. If used with HTTP, curl will enable user authentication. See
  823. .BR netrc(4)
  824. or
  825. .BR ftp(1)
  826. for details on the file format. Curl will not complain if that file
  827. doesn't have the right permissions (it should not be either world- or
  828. group-readable). The environment variable "HOME" is used to find the home
  829. directory.
  830. A quick and very simple example of how to setup a \fI.netrc\fP to allow curl
  831. to FTP to the machine host.domain.com with user name \&'myself' and password
  832. \&'secret' should look similar to:
  833. .B "machine host.domain.com login myself password secret"
  834. .IP "-N, --no-buffer"
  835. Disables the buffering of the output stream. In normal work situations, curl
  836. will use a standard buffered output stream that will have the effect that it
  837. will output the data in chunks, not necessarily exactly when the data arrives.
  838. Using this option will disable that buffering.
  839. Note that this is the negated option name documented. You can thus use
  840. \fI--buffer\fP to enforce the buffering.
  841. .IP "--netrc-file"
  842. This option is similar to \fI--netrc\fP, except that you provide the path
  843. (absolute or relative) to the netrc file that Curl should use.
  844. You can only specify one netrc file per invocation. If several
  845. \fI--netrc-file\fP options are provided, only the \fBlast one\fP will be used.
  846. (Added in 7.21.5)
  847. This option overrides any use of \fI--netrc\fP as they are mutually exclusive.
  848. It will also abide by \fI--netrc-optional\fP if specified.
  849. .IP "--netrc-optional"
  850. Very similar to \fI--netrc\fP, but this option makes the .netrc usage
  851. \fBoptional\fP and not mandatory as the \fI--netrc\fP option does.
  852. .IP "--negotiate"
  853. (HTTP) Enables GSS-Negotiate authentication. The GSS-Negotiate method was
  854. designed by Microsoft and is used in their web applications. It is primarily
  855. meant as a support for Kerberos5 authentication but may be also used along
  856. with another authentication method. For more information see IETF draft
  857. draft-brezak-spnego-http-04.txt.
  858. If you want to enable Negotiate for your proxy authentication, then use
  859. \fI--proxy-negotiate\fP.
  860. This option requires a library built with GSSAPI support. This is
  861. not very common. Use \fI-V, --version\fP to see if your version supports
  862. GSS-Negotiate.
  863. When using this option, you must also provide a fake \fI-u, --user\fP option to
  864. activate the authentication code properly. Sending a '-u :' is enough as the
  865. user name and password from the \fI-u\fP option aren't actually used.
  866. If this option is used several times, only the first one is used.
  867. .IP "--no-keepalive"
  868. Disables the use of keepalive messages on the TCP connection, as by default
  869. curl enables them.
  870. Note that this is the negated option name documented. You can thus use
  871. \fI--keepalive\fP to enforce keepalive.
  872. .IP "--no-sessionid"
  873. (SSL) Disable curl's use of SSL session-ID caching. By default all transfers
  874. are done using the cache. Note that while nothing should ever get hurt by
  875. attempting to reuse SSL session-IDs, there seem to be broken SSL
  876. implementations in the wild that may require you to disable this in order for
  877. you to succeed. (Added in 7.16.0)
  878. Note that this is the negated option name documented. You can thus use
  879. \fI--sessionid\fP to enforce session-ID caching.
  880. .IP "--noproxy <no-proxy-list>"
  881. Comma-separated list of hosts which do not use a proxy, if one is specified.
  882. The only wildcard is a single * character, which matches all hosts, and
  883. effectively disables the proxy. Each name in this list is matched as either
  884. a domain which contains the hostname, or the hostname itself. For example,
  885. local.com would match local.com, local.com:80, and www.local.com, but not
  886. www.notlocal.com. (Added in 7.19.4).
  887. .IP "--ntlm"
  888. (HTTP) Enables NTLM authentication. The NTLM authentication method was
  889. designed by Microsoft and is used by IIS web servers. It is a proprietary
  890. protocol, reverse-engineered by clever people and implemented in curl based
  891. on their efforts. This kind of behavior should not be endorsed, you should
  892. encourage everyone who uses NTLM to switch to a public and documented
  893. authentication method instead, such as Digest.
  894. If you want to enable NTLM for your proxy authentication, then use
  895. \fI--proxy-ntlm\fP.
  896. This option requires a library built with SSL support. Use
  897. \fI-V, --version\fP to see if your curl supports NTLM.
  898. If this option is used several times, only the first one is used.
  899. .IP "-o, --output <file>"
  900. Write output to <file> instead of stdout. If you are using {} or [] to fetch
  901. multiple documents, you can use '#' followed by a number in the <file>
  902. specifier. That variable will be replaced with the current string for the URL
  903. being fetched. Like in:
  904. curl http://{one,two}.site.com -o "file_#1.txt"
  905. or use several variables like:
  906. curl http://{site,host}.host[1-5].com -o "#1_#2"
  907. You may use this option as many times as the number of URLs you have.
  908. See also the \fI--create-dirs\fP option to create the local directories
  909. dynamically. Specifying the output as '-' (a single dash) will force the
  910. output to be done to stdout.
  911. .IP "-O, --remote-name"
  912. Write output to a local file named like the remote file we get. (Only the file
  913. part of the remote file is used, the path is cut off.)
  914. The remote file name to use for saving is extracted from the given URL,
  915. nothing else.
  916. Consequentially, the file will be saved in the current working directory. If
  917. you want the file saved in a different directory, make sure you change current
  918. working directory before you invoke curl with the \fB-O, --remote-name\fP flag!
  919. There is no URL decoding done on the file name. If it has %20 or other URL
  920. encoded parts of the name, they will end up as-is as file name.
  921. You may use this option as many times as the number of URLs you have.
  922. .IP "--oauth2-bearer"
  923. (IMAP, POP3, SMTP)
  924. Specify the Bearer Token for OAUTH 2.0 server authentication. The Bearer Token
  925. is used in conjunction with the user name which can be specified as part of the
  926. \fI--url\fP or \fI-u, --user\fP options.
  927. The Bearer Token and user name are formatted according to RFC 6750.
  928. If this option is used several times, the last one will be used.
  929. .IP "-p, --proxytunnel"
  930. When an HTTP proxy is used (\fI-x, --proxy\fP), this option will cause non-HTTP
  931. protocols to attempt to tunnel through the proxy instead of merely using it to
  932. do HTTP-like operations. The tunnel approach is made with the HTTP proxy
  933. CONNECT request and requires that the proxy allows direct connect to the
  934. remote port number curl wants to tunnel through to.
  935. .IP "-P, --ftp-port <address>"
  936. (FTP) Reverses the default initiator/listener roles when connecting with
  937. FTP. This switch makes curl use active mode. In practice, curl then tells the
  938. server to connect back to the client's specified address and port, while
  939. passive mode asks the server to setup an IP address and port for it to connect
  940. to. <address> should be one of:
  941. .RS
  942. .IP interface
  943. i.e "eth0" to specify which interface's IP address you want to use (Unix only)
  944. .IP "IP address"
  945. i.e "192.168.10.1" to specify the exact IP address
  946. .IP "host name"
  947. i.e "my.host.domain" to specify the machine
  948. .IP "-"
  949. make curl pick the same IP address that is already used for the control
  950. connection
  951. .RE
  952. If this option is used several times, the last one will be used. Disable the
  953. use of PORT with \fI--ftp-pasv\fP. Disable the attempt to use the EPRT command
  954. instead of PORT by using \fI--disable-eprt\fP. EPRT is really PORT++.
  955. Starting in 7.19.5, you can append \&":[start]-[end]\&" to the right of the
  956. address, to tell curl what TCP port range to use. That means you specify a
  957. port range, from a lower to a higher number. A single number works as well,
  958. but do note that it increases the risk of failure since the port may not be
  959. available.
  960. .IP "--pass <phrase>"
  961. (SSL/SSH) Passphrase for the private key
  962. If this option is used several times, the last one will be used.
  963. .IP "--post301"
  964. (HTTP) Tells curl to respect RFC 2616/10.3.2 and not convert POST requests
  965. into GET requests when following a 301 redirection. The non-RFC behaviour is
  966. ubiquitous in web browsers, so curl does the conversion by default to maintain
  967. consistency. However, a server may require a POST to remain a POST after such
  968. a redirection. This option is meaningful only when using \fI-L, --location\fP
  969. (Added in 7.17.1)
  970. .IP "--post302"
  971. (HTTP) Tells curl to respect RFC 2616/10.3.2 and not convert POST requests
  972. into GET requests when following a 302 redirection. The non-RFC behaviour is
  973. ubiquitous in web browsers, so curl does the conversion by default to maintain
  974. consistency. However, a server may require a POST to remain a POST after such
  975. a redirection. This option is meaningful only when using \fI-L, --location\fP
  976. (Added in 7.19.1)
  977. .IP "--post303"
  978. (HTTP) Tells curl to respect RFC 2616/10.3.2 and not convert POST requests
  979. into GET requests when following a 303 redirection. The non-RFC behaviour is
  980. ubiquitous in web browsers, so curl does the conversion by default to maintain
  981. consistency. However, a server may require a POST to remain a POST after such
  982. a redirection. This option is meaningful only when using \fI-L, --location\fP
  983. (Added in 7.26.0)
  984. .IP "--proto <protocols>"
  985. Tells curl to use the listed protocols for its initial retrieval. Protocols
  986. are evaluated left to right, are comma separated, and are each a protocol
  987. name or 'all', optionally prefixed by zero or more modifiers. Available
  988. modifiers are:
  989. .RS
  990. .TP 3
  991. .B +
  992. Permit this protocol in addition to protocols already permitted (this is
  993. the default if no modifier is used).
  994. .TP
  995. .B -
  996. Deny this protocol, removing it from the list of protocols already permitted.
  997. .TP
  998. .B =
  999. Permit only this protocol (ignoring the list already permitted), though
  1000. subject to later modification by subsequent entries in the comma separated
  1001. list.
  1002. .RE
  1003. .IP
  1004. For example:
  1005. .RS
  1006. .TP 15
  1007. .B --proto -ftps
  1008. uses the default protocols, but disables ftps
  1009. .TP
  1010. .B --proto -all,https,+http
  1011. only enables http and https
  1012. .TP
  1013. .B --proto =http,https
  1014. also only enables http and https
  1015. .RE
  1016. .IP
  1017. Unknown protocols produce a warning. This allows scripts to safely rely on
  1018. being able to disable potentially dangerous protocols, without relying upon
  1019. support for that protocol being built into curl to avoid an error.
  1020. This option can be used multiple times, in which case the effect is the same
  1021. as concatenating the protocols into one instance of the option.
  1022. (Added in 7.20.2)
  1023. .IP "--proto-redir <protocols>"
  1024. Tells curl to use the listed protocols after a redirect. See --proto for
  1025. how protocols are represented.
  1026. (Added in 7.20.2)
  1027. .IP "--proxy-anyauth"
  1028. Tells curl to pick a suitable authentication method when communicating with
  1029. the given proxy. This might cause an extra request/response round-trip. (Added
  1030. in 7.13.2)
  1031. .IP "--proxy-basic"
  1032. Tells curl to use HTTP Basic authentication when communicating with the given
  1033. proxy. Use \fI--basic\fP for enabling HTTP Basic with a remote host. Basic is
  1034. the default authentication method curl uses with proxies.
  1035. .IP "--proxy-digest"
  1036. Tells curl to use HTTP Digest authentication when communicating with the given
  1037. proxy. Use \fI--digest\fP for enabling HTTP Digest with a remote host.
  1038. .IP "--proxy-negotiate"
  1039. Tells curl to use HTTP Negotiate authentication when communicating
  1040. with the given proxy. Use \fI--negotiate\fP for enabling HTTP Negotiate
  1041. with a remote host. (Added in 7.17.1)
  1042. .IP "--proxy-ntlm"
  1043. Tells curl to use HTTP NTLM authentication when communicating with the given
  1044. proxy. Use \fI--ntlm\fP for enabling NTLM with a remote host.
  1045. .IP "--proxy1.0 <proxyhost[:port]>"
  1046. Use the specified HTTP 1.0 proxy. If the port number is not specified, it is
  1047. assumed at port 1080.
  1048. The only difference between this and the HTTP proxy option (\fI-x, --proxy\fP),
  1049. is that attempts to use CONNECT through the proxy will specify an HTTP 1.0
  1050. protocol instead of the default HTTP 1.1.
  1051. .IP "--pubkey <key>"
  1052. (SSH) Public key file name. Allows you to provide your public key in this
  1053. separate file.
  1054. If this option is used several times, the last one will be used.
  1055. .IP "-q"
  1056. If used as the first parameter on the command line, the \fIcurlrc\fP config
  1057. file will not be read and used. See the \fI-K, --config\fP for details on the
  1058. default config file search path.
  1059. .IP "-Q, --quote <command>"
  1060. (FTP/SFTP) Send an arbitrary command to the remote FTP or SFTP server. Quote
  1061. commands are sent BEFORE the transfer takes place (just after the initial PWD
  1062. command in an FTP transfer, to be exact). To make commands take place after a
  1063. successful transfer, prefix them with a dash '-'. To make commands be sent
  1064. after curl has changed the working directory, just before the transfer
  1065. command(s), prefix the command with a '+' (this is only supported for
  1066. FTP). You may specify any number of commands. If the server returns failure
  1067. for one of the commands, the entire operation will be aborted. You must send
  1068. syntactically correct FTP commands as RFC 959 defines to FTP servers, or one
  1069. of the commands listed below to SFTP servers. This option can be used
  1070. multiple times. When speaking to an FTP server, prefix the command with an
  1071. asterisk (*) to make curl continue even if the command fails as by default
  1072. curl will stop at first failure.
  1073. SFTP is a binary protocol. Unlike for FTP, curl interprets SFTP quote commands
  1074. itself before sending them to the server. File names may be quoted
  1075. shell-style to embed spaces or special characters. Following is the list of
  1076. all supported SFTP quote commands:
  1077. .RS
  1078. .IP "chgrp group file"
  1079. The chgrp command sets the group ID of the file named by the file operand to
  1080. the group ID specified by the group operand. The group operand is a decimal
  1081. integer group ID.
  1082. .IP "chmod mode file"
  1083. The chmod command modifies the file mode bits of the specified file. The
  1084. mode operand is an octal integer mode number.
  1085. .IP "chown user file"
  1086. The chown command sets the owner of the file named by the file operand to the
  1087. user ID specified by the user operand. The user operand is a decimal
  1088. integer user ID.
  1089. .IP "ln source_file target_file"
  1090. The ln and symlink commands create a symbolic link at the target_file location
  1091. pointing to the source_file location.
  1092. .IP "mkdir directory_name"
  1093. The mkdir command creates the directory named by the directory_name operand.
  1094. .IP "pwd"
  1095. The pwd command returns the absolute pathname of the current working directory.
  1096. .IP "rename source target"
  1097. The rename command renames the file or directory named by the source
  1098. operand to the destination path named by the target operand.
  1099. .IP "rm file"
  1100. The rm command removes the file specified by the file operand.
  1101. .IP "rmdir directory"
  1102. The rmdir command removes the directory entry specified by the directory
  1103. operand, provided it is empty.
  1104. .IP "symlink source_file target_file"
  1105. See ln.
  1106. .RE
  1107. .IP "-r, --range <range>"
  1108. (HTTP/FTP/SFTP/FILE) Retrieve a byte range (i.e a partial document) from a
  1109. HTTP/1.1, FTP or SFTP server or a local FILE. Ranges can be specified
  1110. in a number of ways.
  1111. .RS
  1112. .TP 10
  1113. .B 0-499
  1114. specifies the first 500 bytes
  1115. .TP
  1116. .B 500-999
  1117. specifies the second 500 bytes
  1118. .TP
  1119. .B -500
  1120. specifies the last 500 bytes
  1121. .TP
  1122. .B 9500-
  1123. specifies the bytes from offset 9500 and forward
  1124. .TP
  1125. .B 0-0,-1
  1126. specifies the first and last byte only(*)(H)
  1127. .TP
  1128. .B 500-700,600-799
  1129. specifies 300 bytes from offset 500(H)
  1130. .TP
  1131. .B 100-199,500-599
  1132. specifies two separate 100-byte ranges(*)(H)
  1133. .RE
  1134. (*) = NOTE that this will cause the server to reply with a multipart
  1135. response!
  1136. Only digit characters (0-9) are valid in the 'start' and 'stop' fields of the
  1137. \&'start-stop' range syntax. If a non-digit character is given in the range,
  1138. the server's response will be unspecified, depending on the server's
  1139. configuration.
  1140. You should also be aware that many HTTP/1.1 servers do not have this feature
  1141. enabled, so that when you attempt to get a range, you'll instead get the whole
  1142. document.
  1143. FTP and SFTP range downloads only support the simple 'start-stop' syntax
  1144. (optionally with one of the numbers omitted). FTP use depends on the extended
  1145. FTP command SIZE.
  1146. If this option is used several times, the last one will be used.
  1147. .IP "-R, --remote-time"
  1148. When used, this will make curl attempt to figure out the timestamp of the
  1149. remote file, and if that is available make the local file get that same
  1150. timestamp.
  1151. .IP "--random-file <file>"
  1152. (SSL) Specify the path name to file containing what will be considered as
  1153. random data. The data is used to seed the random engine for SSL connections.
  1154. See also the \fI--egd-file\fP option.
  1155. .IP "--raw"
  1156. (HTTP) When used, it disables all internal HTTP decoding of content or transfer
  1157. encodings and instead makes them passed on unaltered, raw. (Added in 7.16.2)
  1158. .IP "--remote-name-all"
  1159. This option changes the default action for all given URLs to be dealt with as
  1160. if \fI-O, --remote-name\fP were used for each one. So if you want to disable
  1161. that for a specific URL after \fI--remote-name-all\fP has been used, you must
  1162. use "-o -" or \fI--no-remote-name\fP. (Added in 7.19.0)
  1163. .IP "--resolve <host:port:address>"
  1164. Provide a custom address for a specific host and port pair. Using this, you
  1165. can make the curl requests(s) use a specified address and prevent the
  1166. otherwise normally resolved address to be used. Consider it a sort of
  1167. /etc/hosts alternative provided on the command line. The port number should be
  1168. the number used for the specific protocol the host will be used for. It means
  1169. you need several entries if you want to provide address for the same host but
  1170. different ports.
  1171. This option can be used many times to add many host names to resolve.
  1172. (Added in 7.21.3)
  1173. .IP "--retry <num>"
  1174. If a transient error is returned when curl tries to perform a transfer, it
  1175. will retry this number of times before giving up. Setting the number to 0
  1176. makes curl do no retries (which is the default). Transient error means either:
  1177. a timeout, an FTP 4xx response code or an HTTP 5xx response code.
  1178. When curl is about to retry a transfer, it will first wait one second and then
  1179. for all forthcoming retries it will double the waiting time until it reaches
  1180. 10 minutes which then will be the delay between the rest of the retries. By
  1181. using \fI--retry-delay\fP you disable this exponential backoff algorithm. See
  1182. also \fI--retry-max-time\fP to limit the total time allowed for
  1183. retries. (Added in 7.12.3)
  1184. If this option is used several times, the last one will be used.
  1185. .IP "--retry-delay <seconds>"
  1186. Make curl sleep this amount of time before each retry when a transfer has
  1187. failed with a transient error (it changes the default backoff time algorithm
  1188. between retries). This option is only interesting if \fI--retry\fP is also
  1189. used. Setting this delay to zero will make curl use the default backoff time.
  1190. (Added in 7.12.3)
  1191. If this option is used several times, the last one will be used.
  1192. .IP "--retry-max-time <seconds>"
  1193. The retry timer is reset before the first transfer attempt. Retries will be
  1194. done as usual (see \fI--retry\fP) as long as the timer hasn't reached this
  1195. given limit. Notice that if the timer hasn't reached the limit, the request
  1196. will be made and while performing, it may take longer than this given time
  1197. period. To limit a single request\'s maximum time, use \fI-m, --max-time\fP.
  1198. Set this option to zero to not timeout retries. (Added in 7.12.3)
  1199. If this option is used several times, the last one will be used.
  1200. .IP "-s, --silent"
  1201. Silent or quiet mode. Don't show progress meter or error messages. Makes Curl
  1202. mute. It will still output the data you ask for, potentially even to the
  1203. terminal/stdout unless you redirect it.
  1204. .IP "--sasl-ir"
  1205. Enable initial response in SASL authentication.
  1206. (Added in 7.31.0)
  1207. .IP "-S, --show-error"
  1208. When used with \fI-s\fP it makes curl show an error message if it fails.
  1209. .IP "--ssl"
  1210. (FTP, POP3, IMAP, SMTP) Try to use SSL/TLS for the connection. Reverts to a
  1211. non-secure connection if the server doesn't support SSL/TLS. See also
  1212. \fI--ftp-ssl-control\fP and \fI--ssl-reqd\fP for different levels of
  1213. encryption required. (Added in 7.20.0)
  1214. This option was formerly known as \fI--ftp-ssl\fP (Added in 7.11.0). That
  1215. option name can still be used but will be removed in a future version.
  1216. .IP "--ssl-reqd"
  1217. (FTP, POP3, IMAP, SMTP) Require SSL/TLS for the connection. Terminates the
  1218. connection if the server doesn't support SSL/TLS. (Added in 7.20.0)
  1219. This option was formerly known as \fI--ftp-ssl-reqd\fP (added in 7.15.5). That
  1220. option name can still be used but will be removed in a future version.
  1221. .IP "--ssl-allow-beast"
  1222. (SSL) This option tells curl to not work around a security flaw in the SSL3
  1223. and TLS1.0 protocols known as BEAST. If this option isn't used, the SSL layer
  1224. may use work-arounds known to cause interoperability problems with some older
  1225. SSL implementations. WARNING: this option loosens the SSL security, and by
  1226. using this flag you ask for exactly that. (Added in 7.25.0)
  1227. .IP "--socks4 <host[:port]>"
  1228. Use the specified SOCKS4 proxy. If the port number is not specified, it is
  1229. assumed at port 1080. (Added in 7.15.2)
  1230. This option overrides any previous use of \fI-x, --proxy\fP, as they are
  1231. mutually exclusive.
  1232. Since 7.21.7, this option is superfluous since you can specify a socks4 proxy
  1233. with \fI-x, --proxy\fP using a socks4:// protocol prefix.
  1234. If this option is used several times, the last one will be used.
  1235. .IP "--socks4a <host[:port]>"
  1236. Use the specified SOCKS4a proxy. If the port number is not specified, it is
  1237. assumed at port 1080. (Added in 7.18.0)
  1238. This option overrides any previous use of \fI-x, --proxy\fP, as they are
  1239. mutually exclusive.
  1240. Since 7.21.7, this option is superfluous since you can specify a socks4a proxy
  1241. with \fI-x, --proxy\fP using a socks4a:// protocol prefix.
  1242. If this option is used several times, the last one will be used.
  1243. .IP "--socks5-hostname <host[:port]>"
  1244. Use the specified SOCKS5 proxy (and let the proxy resolve the host name). If
  1245. the port number is not specified, it is assumed at port 1080. (Added in
  1246. 7.18.0)
  1247. This option overrides any previous use of \fI-x, --proxy\fP, as they are
  1248. mutually exclusive.
  1249. Since 7.21.7, this option is superfluous since you can specify a socks5
  1250. hostname proxy with \fI-x, --proxy\fP using a socks5h:// protocol prefix.
  1251. If this option is used several times, the last one will be used. (This option
  1252. was previously wrongly documented and used as --socks without the number
  1253. appended.)
  1254. .IP "--socks5 <host[:port]>"
  1255. Use the specified SOCKS5 proxy - but resolve the host name locally. If the
  1256. port number is not specified, it is assumed at port 1080.
  1257. This option overrides any previous use of \fI-x, --proxy\fP, as they are
  1258. mutually exclusive.
  1259. Since 7.21.7, this option is superfluous since you can specify a socks5 proxy
  1260. with \fI-x, --proxy\fP using a socks5:// protocol prefix.
  1261. If this option is used several times, the last one will be used. (This option
  1262. was previously wrongly documented and used as --socks without the number
  1263. appended.)
  1264. This option (as well as \fI--socks4\fP) does not work with IPV6, FTPS or LDAP.
  1265. .IP "--socks5-gssapi-service <servicename>"
  1266. The default service name for a socks server is rcmd/server-fqdn. This option
  1267. allows you to change it.
  1268. Examples: --socks5 proxy-name \fI--socks5-gssapi-service\fP sockd would use
  1269. sockd/proxy-name --socks5 proxy-name \fI--socks5-gssapi-service\fP
  1270. sockd/real-name would use sockd/real-name for cases where the proxy-name does
  1271. not match the principal name. (Added in 7.19.4).
  1272. .IP "--socks5-gssapi-nec"
  1273. As part of the gssapi negotiation a protection mode is negotiated. RFC 1961
  1274. says in section 4.3/4.4 it should be protected, but the NEC reference
  1275. implementation does not. The option \fI--socks5-gssapi-nec\fP allows the
  1276. unprotected exchange of the protection mode negotiation. (Added in 7.19.4).
  1277. .IP "--stderr <file>"
  1278. Redirect all writes to stderr to the specified file instead. If the file name
  1279. is a plain '-', it is instead written to stdout.
  1280. If this option is used several times, the last one will be used.
  1281. .IP "-t, --telnet-option <OPT=val>"
  1282. Pass options to the telnet protocol. Supported options are:
  1283. TTYPE=<term> Sets the terminal type.
  1284. XDISPLOC=<X display> Sets the X display location.
  1285. NEW_ENV=<var,val> Sets an environment variable.
  1286. .IP "-T, --upload-file <file>"
  1287. This transfers the specified local file to the remote URL. If there is no file
  1288. part in the specified URL, Curl will append the local file name. NOTE that you
  1289. must use a trailing / on the last directory to really prove to Curl that there
  1290. is no file name or curl will think that your last directory name is the remote
  1291. file name to use. That will most likely cause the upload operation to fail. If
  1292. this is used on an HTTP(S) server, the PUT command will be used.
  1293. Use the file name "-" (a single dash) to use stdin instead of a given file.
  1294. Alternately, the file name "." (a single period) may be specified instead
  1295. of "-" to use stdin in non-blocking mode to allow reading server output
  1296. while stdin is being uploaded.
  1297. You can specify one -T for each URL on the command line. Each -T + URL pair
  1298. specifies what to upload and to where. curl also supports "globbing" of the -T
  1299. argument, meaning that you can upload multiple files to a single URL by using
  1300. the same URL globbing style supported in the URL, like this:
  1301. curl -T "{file1,file2}" http://www.uploadtothissite.com
  1302. or even
  1303. curl -T "img[1-1000].png" ftp://ftp.picturemania.com/upload/
  1304. .IP "--tcp-nodelay"
  1305. Turn on the TCP_NODELAY option. See the \fIcurl_easy_setopt(3)\fP man page for
  1306. details about this option. (Added in 7.11.2)
  1307. .IP "--tftp-blksize <value>"
  1308. (TFTP) Set TFTP BLKSIZE option (must be >512). This is the block size that
  1309. curl will try to use when transferring data to or from a TFTP server. By
  1310. default 512 bytes will be used.
  1311. If this option is used several times, the last one will be used.
  1312. (Added in 7.20.0)
  1313. .IP "--tlsauthtype <authtype>"
  1314. Set TLS authentication type. Currently, the only supported option is "SRP",
  1315. for TLS-SRP (RFC 5054). If \fI--tlsuser\fP and \fI--tlspassword\fP are
  1316. specified but \fI--tlsauthtype\fP is not, then this option defaults to "SRP".
  1317. (Added in 7.21.4)
  1318. .IP "--tlspassword <password>"
  1319. Set password for use with the TLS authentication method specified with
  1320. \fI--tlsauthtype\fP. Requires that \fI--tlsuser\fP also be set. (Added in
  1321. 7.21.4)
  1322. .IP "--tlsuser <user>"
  1323. Set username for use with the TLS authentication method specified with
  1324. \fI--tlsauthtype\fP. Requires that \fI--tlspassword\fP also be set. (Added in
  1325. 7.21.4)
  1326. .IP "--tlsv1.0"
  1327. (SSL)
  1328. Forces curl to use TLS version 1.0 when negotiating with a remote TLS server.
  1329. (Added in 7.34.0)
  1330. .IP "--tlsv1.1"
  1331. (SSL)
  1332. Forces curl to use TLS version 1.1 when negotiating with a remote TLS server.
  1333. (Added in 7.34.0)
  1334. .IP "--tlsv1.2"
  1335. (SSL)
  1336. Forces curl to use TLS version 1.2 when negotiating with a remote TLS server.
  1337. (Added in 7.34.0)
  1338. .IP "--tr-encoding"
  1339. (HTTP) Request a compressed Transfer-Encoding response using one of the
  1340. algorithms curl supports, and uncompress the data while receiving it.
  1341. (Added in 7.21.6)
  1342. .IP "--trace <file>"
  1343. Enables a full trace dump of all incoming and outgoing data, including
  1344. descriptive information, to the given output file. Use "-" as filename to have
  1345. the output sent to stdout.
  1346. This option overrides previous uses of \fI-v, --verbose\fP or
  1347. \fI--trace-ascii\fP.
  1348. If this option is used several times, the last one will be used.
  1349. .IP "--trace-ascii <file>"
  1350. Enables a full trace dump of all incoming and outgoing data, including
  1351. descriptive information, to the given output file. Use "-" as filename to have
  1352. the output sent to stdout.
  1353. This is very similar to \fI--trace\fP, but leaves out the hex part and only
  1354. shows the ASCII part of the dump. It makes smaller output that might be easier
  1355. to read for untrained humans.
  1356. This option overrides previous uses of \fI-v, --verbose\fP or \fI--trace\fP.
  1357. If this option is used several times, the last one will be used.
  1358. .IP "--trace-time"
  1359. Prepends a time stamp to each trace or verbose line that curl displays.
  1360. (Added in 7.14.0)
  1361. .IP "-u, --user <user:password;options>"
  1362. Specify the user name, password and optional login options to use for server
  1363. authentication. Overrides \fI-n, --netrc\fP and \fI--netrc-optional\fP.
  1364. If you simply specify the user name, with or without the login options, curl
  1365. will prompt for a password.
  1366. If you use an SSPI-enabled curl binary and perform NTLM authentication, you
  1367. can force curl to select the user name and password from your environment by
  1368. simply specifying a single colon with this option: "-u :" or by specfying the
  1369. login options on their own, for example "-u ;auth=NTLM".
  1370. You can use the optional login options part to specify protocol specific
  1371. options that may be used during authentication. At present only IMAP, POP3 and
  1372. SMTP support login options as part of the user login information. For more
  1373. information about the login options please see RFC 2384, RFC 5092 and IETF
  1374. draft draft-earhart-url-smtp-00.txt (Added in 7.31.0).
  1375. If this option is used several times, the last one will be used.
  1376. .IP "-U, --proxy-user <user:password>"
  1377. Specify the user name and password to use for proxy authentication.
  1378. If you use an SSPI-enabled curl binary and do NTLM authentication, you can
  1379. force curl to pick up the user name and password from your environment by
  1380. simply specifying a single colon with this option: "-U :".
  1381. If this option is used several times, the last one will be used.
  1382. .IP "--url <URL>"
  1383. Specify a URL to fetch. This option is mostly handy when you want to specify
  1384. URL(s) in a config file.
  1385. This option may be used any number of times. To control where this URL is
  1386. written, use the \fI-o, --output\fP or the \fI-O, --remote-name\fP options.
  1387. .IP "-v, --verbose"
  1388. Makes the fetching more verbose/talkative. Mostly useful for debugging. A line
  1389. starting with '>' means "header data" sent by curl, '<' means "header data"
  1390. received by curl that is hidden in normal cases, and a line starting with '*'
  1391. means additional info provided by curl.
  1392. Note that if you only want HTTP headers in the output, \fI-i, --include\fP
  1393. might be the option you're looking for.
  1394. If you think this option still doesn't give you enough details, consider using
  1395. \fI--trace\fP or \fI--trace-ascii\fP instead.
  1396. This option overrides previous uses of \fI--trace-ascii\fP or \fI--trace\fP.
  1397. Use \fI-s, --silent\fP to make curl quiet.
  1398. .IP "-w, --write-out <format>"
  1399. Defines what to display on stdout after a completed and successful
  1400. operation. The format is a string that may contain plain text mixed with any
  1401. number of variables. The string can be specified as "string", to get read from
  1402. a particular file you specify it "@filename" and to tell curl to read the
  1403. format from stdin you write "@-".
  1404. The variables present in the output format will be substituted by the value or
  1405. text that curl thinks fit, as described below. All variables are specified
  1406. as %{variable_name} and to output a normal % you just write them as
  1407. %%. You can output a newline by using \\n, a carriage return with \\r and a tab
  1408. space with \\t.
  1409. .B NOTE:
  1410. The %-symbol is a special symbol in the win32-environment, where all
  1411. occurrences of % must be doubled when using this option.
  1412. The variables available are:
  1413. .RS
  1414. .TP 15
  1415. .B content_type
  1416. The Content-Type of the requested document, if there was any.
  1417. .TP
  1418. .B filename_effective
  1419. The ultimate filename that curl writes out to. This is only meaningful if curl
  1420. is told to write to a file with the \fI--remote-name\fP or \fI--output\fP
  1421. option. It's most useful in combination with the \fI--remote-header-name\fP
  1422. option. (Added in 7.25.1)
  1423. .TP
  1424. .B ftp_entry_path
  1425. The initial path curl ended up in when logging on to the remote FTP
  1426. server. (Added in 7.15.4)
  1427. .TP
  1428. .B http_code
  1429. The numerical response code that was found in the last retrieved HTTP(S) or
  1430. FTP(s) transfer. In 7.18.2 the alias \fBresponse_code\fP was added to show the
  1431. same info.
  1432. .TP
  1433. .B http_connect
  1434. The numerical code that was found in the last response (from a proxy) to a
  1435. curl CONNECT request. (Added in 7.12.4)
  1436. .TP
  1437. .B local_ip
  1438. The IP address of the local end of the most recently done connection - can be
  1439. either IPv4 or IPv6 (Added in 7.29.0)
  1440. .TP
  1441. .B local_port
  1442. The local port number of the most recently done connection (Added in 7.29.0)
  1443. .TP
  1444. .B num_connects
  1445. Number of new connects made in the recent transfer. (Added in 7.12.3)
  1446. .TP
  1447. .B num_redirects
  1448. Number of redirects that were followed in the request. (Added in 7.12.3)
  1449. .TP
  1450. .B redirect_url
  1451. When an HTTP request was made without -L to follow redirects, this variable
  1452. will show the actual URL a redirect \fIwould\fP take you to. (Added in 7.18.2)
  1453. .TP
  1454. .B remote_ip
  1455. The remote IP address of the most recently done connection - can be either
  1456. IPv4 or IPv6 (Added in 7.29.0)
  1457. .TP
  1458. .B remote_port
  1459. The remote port number of the most recently done connection (Added in 7.29.0)
  1460. .TP
  1461. .B size_download
  1462. The total amount of bytes that were downloaded.
  1463. .TP
  1464. .B size_header
  1465. The total amount of bytes of the downloaded headers.
  1466. .TP
  1467. .B size_request
  1468. The total amount of bytes that were sent in the HTTP request.
  1469. .TP
  1470. .B size_upload
  1471. The total amount of bytes that were uploaded.
  1472. .TP
  1473. .B speed_download
  1474. The average download speed that curl measured for the complete download. Bytes
  1475. per second.
  1476. .TP
  1477. .B speed_upload
  1478. The average upload speed that curl measured for the complete upload. Bytes per
  1479. second.
  1480. .TP
  1481. .B ssl_verify_result
  1482. The result of the SSL peer certificate verification that was requested. 0
  1483. means the verification was successful. (Added in 7.19.0)
  1484. .TP
  1485. .B time_appconnect
  1486. The time, in seconds, it took from the start until the SSL/SSH/etc
  1487. connect/handshake to the remote host was completed. (Added in 7.19.0)
  1488. .TP
  1489. .B time_connect
  1490. The time, in seconds, it took from the start until the TCP connect to the
  1491. remote host (or proxy) was completed.
  1492. .TP
  1493. .B time_namelookup
  1494. The time, in seconds, it took from the start until the name resolving was
  1495. completed.
  1496. .TP
  1497. .B time_pretransfer
  1498. The time, in seconds, it took from the start until the file transfer was just
  1499. about to begin. This includes all pre-transfer commands and negotiations that
  1500. are specific to the particular protocol(s) involved.
  1501. .TP
  1502. .B time_redirect
  1503. The time, in seconds, it took for all redirection steps include name lookup,
  1504. connect, pretransfer and transfer before the final transaction was
  1505. started. time_redirect shows the complete execution time for multiple
  1506. redirections. (Added in 7.12.3)
  1507. .TP
  1508. .B time_starttransfer
  1509. The time, in seconds, it took from the start until the first byte was just
  1510. about to be transferred. This includes time_pretransfer and also the time the
  1511. server needed to calculate the result.
  1512. .TP
  1513. .B time_total
  1514. The total time, in seconds, that the full operation lasted. The time will be
  1515. displayed with millisecond resolution.
  1516. .TP
  1517. .B url_effective
  1518. The URL that was fetched last. This is most meaningful if you've told curl
  1519. to follow location: headers.
  1520. .RE
  1521. If this option is used several times, the last one will be used.
  1522. .IP "-x, --proxy <[protocol://][user:password@]proxyhost[:port]>"
  1523. Use the specified proxy.
  1524. The proxy string can be specified with a protocol:// prefix to specify
  1525. alternative proxy protocols. Use socks4://, socks4a://, socks5:// or
  1526. socks5h:// to request the specific SOCKS version to be used. No protocol
  1527. specified, http:// and all others will be treated as HTTP proxies. (The
  1528. protocol support was added in curl 7.21.7)
  1529. If the port number is not specified in the proxy string, it is assumed to be
  1530. 1080.
  1531. This option overrides existing environment variables that set the proxy to
  1532. use. If there's an environment variable setting a proxy, you can set proxy to
  1533. \&"" to override it.
  1534. All operations that are performed over an HTTP proxy will transparently be
  1535. converted to HTTP. It means that certain protocol specific operations might
  1536. not be available. This is not the case if you can tunnel through the proxy, as
  1537. one with the \fI-p, --proxytunnel\fP option.
  1538. User and password that might be provided in the proxy string are URL decoded
  1539. by curl. This allows you to pass in special characters such as @ by using %40
  1540. or pass in a colon with %3a.
  1541. The proxy host can be specified the exact same way as the proxy environment
  1542. variables, including the protocol prefix (http://) and the embedded user +
  1543. password.
  1544. If this option is used several times, the last one will be used.
  1545. .IP "-X, --request <command>"
  1546. (HTTP) Specifies a custom request method to use when communicating with the
  1547. HTTP server. The specified request will be used instead of the method
  1548. otherwise used (which defaults to GET). Read the HTTP 1.1 specification for
  1549. details and explanations. Common additional HTTP requests include PUT and
  1550. DELETE, but related technologies like WebDAV offers PROPFIND, COPY, MOVE and
  1551. more.
  1552. Normally you don't need this option. All sorts of GET, HEAD, POST and PUT
  1553. requests are rather invoked by using dedicated command line options.
  1554. This option only changes the actual word used in the HTTP request, it does not
  1555. alter the way curl behaves. So for example if you want to make a proper HEAD
  1556. request, using -X HEAD will not suffice. You need to use the \fI-I, --head\fP
  1557. option.
  1558. (FTP)
  1559. Specifies a custom FTP command to use instead of LIST when doing file lists
  1560. with FTP.
  1561. (POP3)
  1562. Specifies a custom POP3 command to use instead of LIST or RETR. (Added in
  1563. 7.26.0)
  1564. (IMAP)
  1565. Specifies a custom IMAP command to use insead of LIST. (Added in 7.30.0)
  1566. (SMTP)
  1567. Specifies a custom SMTP command to use instead of HELP or VRFY. (Added in 7.34.0)
  1568. If this option is used several times, the last one will be used.
  1569. .IP "--xattr"
  1570. When saving output to a file, this option tells curl to store certain file
  1571. metadata in extended file attributes. Currently, the URL is stored in the
  1572. xdg.origin.url attribute and, for HTTP, the content type is stored in
  1573. the mime_type attribute. If the file system does not support extended
  1574. attributes, a warning is issued.
  1575. .IP "-y, --speed-time <time>"
  1576. If a download is slower than speed-limit bytes per second during a speed-time
  1577. period, the download gets aborted. If speed-time is used, the default
  1578. speed-limit will be 1 unless set with \fI-Y\fP.
  1579. This option controls transfers and thus will not affect slow connects etc. If
  1580. this is a concern for you, try the \fI--connect-timeout\fP option.
  1581. If this option is used several times, the last one will be used.
  1582. .IP "-Y, --speed-limit <speed>"
  1583. If a download is slower than this given speed (in bytes per second) for
  1584. speed-time seconds it gets aborted. speed-time is set with \fI-y\fP and is 30
  1585. if not set.
  1586. If this option is used several times, the last one will be used.
  1587. .IP "-z, --time-cond <date expression>|<file>"
  1588. (HTTP/FTP) Request a file that has been modified later than the given time and
  1589. date, or one that has been modified before that time. The <date expression>
  1590. can be all sorts of date strings or if it doesn't match any internal ones, it
  1591. is taken as a filename and tries to get the modification date (mtime) from
  1592. <file> instead. See the \fIcurl_getdate(3)\fP man pages for date expression
  1593. details.
  1594. Start the date expression with a dash (-) to make it request for a document
  1595. that is older than the given date/time, default is a document that is newer
  1596. than the specified date/time.
  1597. If this option is used several times, the last one will be used.
  1598. .IP "-h, --help"
  1599. Usage help.
  1600. .IP "-M, --manual"
  1601. Manual. Display the huge help text.
  1602. .IP "-V, --version"
  1603. Displays information about curl and the libcurl version it uses.
  1604. The first line includes the full version of curl, libcurl and other 3rd party
  1605. libraries linked with the executable.
  1606. The second line (starts with "Protocols:") shows all protocols that libcurl
  1607. reports to support.
  1608. The third line (starts with "Features:") shows specific features libcurl
  1609. reports to offer. Available features include:
  1610. .RS
  1611. .IP "IPv6"
  1612. You can use IPv6 with this.
  1613. .IP "krb4"
  1614. Krb4 for FTP is supported.
  1615. .IP "SSL"
  1616. HTTPS and FTPS are supported.
  1617. .IP "libz"
  1618. Automatic decompression of compressed files over HTTP is supported.
  1619. .IP "NTLM"
  1620. NTLM authentication is supported.
  1621. .IP "GSS-Negotiate"
  1622. Negotiate authentication and krb5 for FTP is supported.
  1623. .IP "Debug"
  1624. This curl uses a libcurl built with Debug. This enables more error-tracking
  1625. and memory debugging etc. For curl-developers only!
  1626. .IP "AsynchDNS"
  1627. This curl uses asynchronous name resolves.
  1628. .IP "SPNEGO"
  1629. SPNEGO Negotiate authentication is supported.
  1630. .IP "Largefile"
  1631. This curl supports transfers of large files, files larger than 2GB.
  1632. .IP "IDN"
  1633. This curl supports IDN - international domain names.
  1634. .IP "SSPI"
  1635. SSPI is supported. If you use NTLM and set a blank user name, curl will
  1636. authenticate with your current user and password.
  1637. .IP "TLS-SRP"
  1638. SRP (Secure Remote Password) authentication is supported for TLS.
  1639. .IP "Metalink"
  1640. This curl supports Metalink (both version 3 and 4 (RFC 5854)), which
  1641. describes mirrors and hashes. curl will use mirrors for failover if
  1642. there are errors (such as the file or server not being available).
  1643. .RE
  1644. .SH FILES
  1645. .I ~/.curlrc
  1646. .RS
  1647. Default config file, see \fI-K, --config\fP for details.
  1648. .SH ENVIRONMENT
  1649. The environment variables can be specified in lower case or upper case. The
  1650. lower case version has precedence. http_proxy is an exception as it is only
  1651. available in lower case.
  1652. Using an environment variable to set the proxy has the same effect as using
  1653. the \fI--proxy\fP option.
  1654. .IP "http_proxy [protocol://]<host>[:port]"
  1655. Sets the proxy server to use for HTTP.
  1656. .IP "HTTPS_PROXY [protocol://]<host>[:port]"
  1657. Sets the proxy server to use for HTTPS.
  1658. .IP "[url-protocol]_PROXY [protocol://]<host>[:port]"
  1659. Sets the proxy server to use for [url-protocol], where the protocol is a
  1660. protocol that curl supports and as specified in a URL. FTP, FTPS, POP3, IMAP,
  1661. SMTP, LDAP etc.
  1662. .IP "ALL_PROXY [protocol://]<host>[:port]"
  1663. Sets the proxy server to use if no protocol-specific proxy is set.
  1664. .IP "NO_PROXY <comma-separated list of hosts>"
  1665. list of host names that shouldn't go through any proxy. If set to a asterisk
  1666. \&'*' only, it matches all hosts.
  1667. .SH "PROXY PROTOCOL PREFIXES"
  1668. Since curl version 7.21.7, the proxy string may be specified with a
  1669. protocol:// prefix to specify alternative proxy protocols.
  1670. If no protocol is specified in the proxy string or if the string doesn't match
  1671. a supported one, the proxy will be treated as an HTTP proxy.
  1672. The supported proxy protocol prefixes are as follows:
  1673. .IP "socks4://"
  1674. Makes it the equivalent of \fI--socks4\fP
  1675. .IP "socks4a://"
  1676. Makes it the equivalent of \fI--socks4a\fP
  1677. .IP "socks5://"
  1678. Makes it the equivalent of \fI--socks5\fP
  1679. .IP "socks5h://"
  1680. Makes it the equivalent of \fI--socks5-hostname\fP
  1681. .SH EXIT CODES
  1682. There are a bunch of different error codes and their corresponding error
  1683. messages that may appear during bad conditions. At the time of this writing,
  1684. the exit codes are:
  1685. .IP 1
  1686. Unsupported protocol. This build of curl has no support for this protocol.
  1687. .IP 2
  1688. Failed to initialize.
  1689. .IP 3
  1690. URL malformed. The syntax was not correct.
  1691. .IP 4
  1692. A feature or option that was needed to perform the desired request was not
  1693. enabled or was explicitly disabled at build-time. To make curl able to do
  1694. this, you probably need another build of libcurl!
  1695. .IP 5
  1696. Couldn't resolve proxy. The given proxy host could not be resolved.
  1697. .IP 6
  1698. Couldn't resolve host. The given remote host was not resolved.
  1699. .IP 7
  1700. Failed to connect to host.
  1701. .IP 8
  1702. FTP weird server reply. The server sent data curl couldn't parse.
  1703. .IP 9
  1704. FTP access denied. The server denied login or denied access to the particular
  1705. resource or directory you wanted to reach. Most often you tried to change to a
  1706. directory that doesn't exist on the server.
  1707. .IP 11
  1708. FTP weird PASS reply. Curl couldn't parse the reply sent to the PASS request.
  1709. .IP 13
  1710. FTP weird PASV reply, Curl couldn't parse the reply sent to the PASV request.
  1711. .IP 14
  1712. FTP weird 227 format. Curl couldn't parse the 227-line the server sent.
  1713. .IP 15
  1714. FTP can't get host. Couldn't resolve the host IP we got in the 227-line.
  1715. .IP 17
  1716. FTP couldn't set binary. Couldn't change transfer method to binary.
  1717. .IP 18
  1718. Partial file. Only a part of the file was transferred.
  1719. .IP 19
  1720. FTP couldn't download/access the given file, the RETR (or similar) command
  1721. failed.
  1722. .IP 21
  1723. FTP quote error. A quote command returned error from the server.
  1724. .IP 22
  1725. HTTP page not retrieved. The requested url was not found or returned another
  1726. error with the HTTP error code being 400 or above. This return code only
  1727. appears if \fI-f, --fail\fP is used.
  1728. .IP 23
  1729. Write error. Curl couldn't write data to a local filesystem or similar.
  1730. .IP 25
  1731. FTP couldn't STOR file. The server denied the STOR operation, used for FTP
  1732. uploading.
  1733. .IP 26
  1734. Read error. Various reading problems.
  1735. .IP 27
  1736. Out of memory. A memory allocation request failed.
  1737. .IP 28
  1738. Operation timeout. The specified time-out period was reached according to the
  1739. conditions.
  1740. .IP 30
  1741. FTP PORT failed. The PORT command failed. Not all FTP servers support the PORT
  1742. command, try doing a transfer using PASV instead!
  1743. .IP 31
  1744. FTP couldn't use REST. The REST command failed. This command is used for
  1745. resumed FTP transfers.
  1746. .IP 33
  1747. HTTP range error. The range "command" didn't work.
  1748. .IP 34
  1749. HTTP post error. Internal post-request generation error.
  1750. .IP 35
  1751. SSL connect error. The SSL handshaking failed.
  1752. .IP 36
  1753. FTP bad download resume. Couldn't continue an earlier aborted download.
  1754. .IP 37
  1755. FILE couldn't read file. Failed to open the file. Permissions?
  1756. .IP 38
  1757. LDAP cannot bind. LDAP bind operation failed.
  1758. .IP 39
  1759. LDAP search failed.
  1760. .IP 41
  1761. Function not found. A required LDAP function was not found.
  1762. .IP 42
  1763. Aborted by callback. An application told curl to abort the operation.
  1764. .IP 43
  1765. Internal error. A function was called with a bad parameter.
  1766. .IP 45
  1767. Interface error. A specified outgoing interface could not be used.
  1768. .IP 47
  1769. Too many redirects. When following redirects, curl hit the maximum amount.
  1770. .IP 48
  1771. Unknown option specified to libcurl. This indicates that you passed a weird
  1772. option to curl that was passed on to libcurl and rejected. Read up in the
  1773. manual!
  1774. .IP 49
  1775. Malformed telnet option.
  1776. .IP 51
  1777. The peer's SSL certificate or SSH MD5 fingerprint was not OK.
  1778. .IP 52
  1779. The server didn't reply anything, which here is considered an error.
  1780. .IP 53
  1781. SSL crypto engine not found.
  1782. .IP 54
  1783. Cannot set SSL crypto engine as default.
  1784. .IP 55
  1785. Failed sending network data.
  1786. .IP 56
  1787. Failure in receiving network data.
  1788. .IP 58
  1789. Problem with the local certificate.
  1790. .IP 59
  1791. Couldn't use specified SSL cipher.
  1792. .IP 60
  1793. Peer certificate cannot be authenticated with known CA certificates.
  1794. .IP 61
  1795. Unrecognized transfer encoding.
  1796. .IP 62
  1797. Invalid LDAP URL.
  1798. .IP 63
  1799. Maximum file size exceeded.
  1800. .IP 64
  1801. Requested FTP SSL level failed.
  1802. .IP 65
  1803. Sending the data requires a rewind that failed.
  1804. .IP 66
  1805. Failed to initialise SSL Engine.
  1806. .IP 67
  1807. The user name, password, or similar was not accepted and curl failed to log in.
  1808. .IP 68
  1809. File not found on TFTP server.
  1810. .IP 69
  1811. Permission problem on TFTP server.
  1812. .IP 70
  1813. Out of disk space on TFTP server.
  1814. .IP 71
  1815. Illegal TFTP operation.
  1816. .IP 72
  1817. Unknown TFTP transfer ID.
  1818. .IP 73
  1819. File already exists (TFTP).
  1820. .IP 74
  1821. No such user (TFTP).
  1822. .IP 75
  1823. Character conversion failed.
  1824. .IP 76
  1825. Character conversion functions required.
  1826. .IP 77
  1827. Problem with reading the SSL CA cert (path? access rights?).
  1828. .IP 78
  1829. The resource referenced in the URL does not exist.
  1830. .IP 79
  1831. An unspecified error occurred during the SSH session.
  1832. .IP 80
  1833. Failed to shut down the SSL connection.
  1834. .IP 82
  1835. Could not load CRL file, missing or wrong format (added in 7.19.0).
  1836. .IP 83
  1837. Issuer check failed (added in 7.19.0).
  1838. .IP 84
  1839. The FTP PRET command failed
  1840. .IP 85
  1841. RTSP: mismatch of CSeq numbers
  1842. .IP 86
  1843. RTSP: mismatch of Session Identifiers
  1844. .IP 87
  1845. unable to parse FTP file list
  1846. .IP 88
  1847. FTP chunk callback reported error
  1848. .IP 89
  1849. No connection available, the session will be queued
  1850. .IP XX
  1851. More error codes will appear here in future releases. The existing ones
  1852. are meant to never change.
  1853. .SH AUTHORS / CONTRIBUTORS
  1854. Daniel Stenberg is the main author, but the whole list of contributors is
  1855. found in the separate THANKS file.
  1856. .SH WWW
  1857. http://curl.haxx.se
  1858. .SH FTP
  1859. ftp://ftp.sunet.se/pub/www/utilities/curl/
  1860. .SH "SEE ALSO"
  1861. .BR ftp (1),
  1862. .BR wget (1)