Curl: Difference between revisions
Content added Content deleted
(Page created) |
(template added) |
||
Line 1: | Line 1: | ||
[[Category:Linux]] |
|||
⚫ | |||
__TOC__ |
|||
<br /> |
|||
Curl is a tool to transfer data from or to a server, using one of the supported protocols |
|||
DICT, FILE, FTP, FTPS, GOPHER, HTTP, HTTPS, IMAP, IMAPS, LDAP, LDAPS, POP3, POP3S, RTMP, RTSP, SCP, SFTP, SMB, SMBS, SMTP, SMTPS, TELNET and TFTP. |
DICT, FILE, FTP, FTPS, GOPHER, HTTP, HTTPS, IMAP, IMAPS, LDAP, LDAPS, POP3, POP3S, RTMP, RTSP, SCP, SFTP, SMB, SMBS, SMTP, SMTPS, TELNET and TFTP. |
||
Curl command has the following functionality: |
|||
<div style="column-count:3;-moz-column-count:3;-webkit-column-count:3"> |
|||
Multiple URLs |
Multiple URLs |
||
Usernames and Passwords support |
Usernames and Passwords support |
||
Line 56: | Line 59: | ||
FTP Connection re-use |
FTP Connection re-use |
||
GOPHER |
GOPHER |
||
</div> |
|||
=One-Liners= |
=One-Liners= |
||
Save the output of the URL to a file curl -o website https://domain.com |
Save the output of the URL to a file curl -o website https://domain.com |
||
Download files with cURL curl -O https://domain.com/file.zip |
Download files with cURL curl -O https://domain.com/file.zip |
||
curl -O https://domain.com/file.zip -O https://domain.com/file2.zip |
|||
curl -o archive.zip https://domain.com/file.zip |
|||
Download files securely via SSH curl -u user sftp://server.domain.com/path/to/file |
Download files securely via SSH curl -u user sftp://server.domain.com/path/to/file |
||
Get HTTP header information curl -I http://domain.com |
Get HTTP header information curl -I http://domain.com |
||
Access an FTP server curl ftp://ftp.domain.com --user username:password |
Access an FTP server curl ftp://ftp.domain.com --user username:password |
||
Download a file via FTP curl ftp://ftp.domain.com/file.zip --user username:password |
Download a file via FTP curl ftp://ftp.domain.com/file.zip --user username:password |
||
Upload a file to the FTP server curl -T file.zip ftp://ftp.domain.com/ --user username:password |
Upload a file to the FTP server curl -T file.zip ftp://ftp.domain.com/ --user username:password |
||
Line 100: | Line 104: | ||
Cookie -b |
Cookie -b |
||
Cookie-jar(file curl should use to save all cookies) -c |
Cookie-jar(file curl should use to save all cookies) -c |
||
⚫ | |||
<br /> |
|||
;References |
|||
<references/> |
|||
<br /> |
|||
<br /> |
|||
<br /> |
|||
{{DISQUS}} |