差分
このページの2つのバージョン間の差分を表示します。
両方とも前のリビジョン 前のリビジョン 次のリビジョン | 前のリビジョン | ||
linux:curl [2020/09/13 03:37] – [cURL - クライアントサイドURL転送ライブラリ] ともやん | linux:curl [2025/02/26 09:25] (現在) – [cURL - クライアントサイドURL転送ライブラリ] ともやん | ||
---|---|---|---|
行 1: | 行 1: | ||
====== cURL - クライアントサイドURL転送ライブラリ ====== | ====== cURL - クライアントサイドURL転送ライブラリ ====== | ||
- | {{linux: | + | <WRAP zoomimg w250 x1_2 fsizemin> |
- | ※日本では明治製菓の「おやつはカール」❓😅💦💦💦 チーズ味最高です💕\\ | + | {{linux: |
+ | <WRAP desc> | ||
+ | ※日本では明治製菓の「おやつはカール」がイメージです❓😅💦💦💦 チーズ味最高です💕\\ | ||
+ | </ | ||
+ | </ | ||
**cURL** (カール) は、さまざまなプロトコルを用いてデータを転送するライブラリとコマンドラインツールを提供するプロジェクトである。cURL プロジェクトは libcurl と curl の2つの成果を生んでいる。\\ | **cURL** (カール) は、さまざまなプロトコルを用いてデータを転送するライブラリとコマンドラインツールを提供するプロジェクトである。cURL プロジェクトは libcurl と curl の2つの成果を生んでいる。\\ | ||
- | 本家: [[https:// | + | 本家: [[https:// |
+ | ドキュメント: | ||
ソースコード: | ソースコード: | ||
行 10: | 行 16: | ||
===== インストール ===== | ===== インストール ===== | ||
- | Fedora\\ | + | **Fedora** では既にインストール済みである🤔\\ |
+ | <WRAP color_term> | ||
+ | <WRAP color_command>< | ||
+ | <b class=GRN> | ||
+ | </ | ||
+ | <WRAP color_result>< | ||
+ | メタデータの期限切れの最終確認: | ||
+ | パッケージ curl-7.85.0-7.fc37.x86_64 は既にインストールされています。 | ||
+ | 依存関係が解決しました。 | ||
+ | 行うべきことはありません。 | ||
+ | 完了しました! | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | 動作確認🤤\\ | ||
+ | <WRAP color_term> | ||
+ | <WRAP color_command>< | ||
+ | <b class=GRN> | ||
+ | </ | ||
+ | <WRAP color_result>< | ||
+ | curl 7.85.0 (x86_64-redhat-linux-gnu) libcurl/ | ||
+ | Release-Date: | ||
+ | Protocols: dict file ftp ftps gopher gophers http https imap imaps ldap ldaps mqtt pop3 pop3s rtsp scp sftp smb smbs smtp smtps telnet tftp | ||
+ | Features: alt-svc AsynchDNS brotli GSS-API HSTS HTTP2 HTTPS-proxy IDN IPv6 Kerberos Largefile libz NTLM NTLM_WB PSL SPNEGO SSL threadsafe TLS-SRP UnixSockets | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | ===== コマンドライン オプション ===== | ||
+ | |||
+ | ==== バージョン表示 [-V, --version] ==== | ||
+ | <WRAP color_term> | ||
+ | <WRAP color_command>< | ||
+ | <b class=GRN> | ||
+ | </ | ||
+ | <WRAP color_result>< | ||
+ | curl 7.85.0 (x86_64-redhat-linux-gnu) libcurl/ | ||
+ | Release-Date: | ||
+ | Protocols: dict file ftp ftps gopher gophers http https imap imaps ldap ldaps mqtt pop3 pop3s rtsp scp sftp smb smbs smtp smtps telnet tftp | ||
+ | Features: alt-svc AsynchDNS brotli GSS-API HSTS HTTP2 HTTPS-proxy IDN IPv6 Kerberos Largefile libz NTLM NTLM_WB PSL SPNEGO SSL threadsafe TLS-SRP UnixSockets | ||
+ | </ | ||
+ | </ | ||
+ | or\\ | ||
+ | <WRAP color_term> | ||
+ | <WRAP color_command>< | ||
+ | <b class=GRN> | ||
+ | </ | ||
+ | <WRAP color_result>< | ||
+ | curl 7.55.1 (Windows) libcurl/ | ||
+ | Release-Date: | ||
+ | Protocols: dict file ftp ftps http https imap imaps pop3 pop3s smtp smtps telnet tftp | ||
+ | Features: AsynchDNS IPv6 Largefile SSPI Kerberos SPNEGO NTLM SSL | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | ==== ヘルプ [-h, --help] ==== | ||
+ | <WRAP color_term> | ||
+ | <WRAP color_command>< | ||
+ | <b class=GRN> | ||
+ | </ | ||
+ | <WRAP color_mincode>< | ||
+ | Usage: curl [options...] < | ||
+ | -d, --data < | ||
+ | -f, --fail | ||
+ | -h, --help < | ||
+ | -i, --include | ||
+ | -o, --output < | ||
+ | -O, --remote-name | ||
+ | -s, --silent | ||
+ | -T, --upload-file < | ||
+ | -u, --user < | ||
+ | -A, --user-agent < | ||
+ | -v, --verbose | ||
+ | -V, --version | ||
+ | |||
+ | This is not the full help, this menu is stripped into categories. | ||
+ | Use " | ||
+ | For all options use the manual or " | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | **curl** コマンドは機能があり過ぎです😅💦💦💦\\ | ||
+ | <WRAP color_term> | ||
+ | <WRAP color_command>< | ||
+ | <b class=GRN> | ||
+ | </ | ||
+ | <WRAP color_mincode_long>< | ||
+ | Usage: curl [options...] < | ||
+ | -d, --data < | ||
+ | -f, --fail | ||
+ | -h, --help < | ||
+ | -i, --include | ||
+ | -o, --output < | ||
+ | -O, --remote-name | ||
+ | -s, --silent | ||
+ | -T, --upload-file < | ||
+ | -u, --user < | ||
+ | -A, --user-agent < | ||
+ | -v, --verbose | ||
+ | -V, --version | ||
+ | |||
+ | This is not the full help, this menu is stripped into categories. | ||
+ | Use " | ||
+ | For all options use the manual or " | ||
+ | [tomoyan@WICKED-BEAT development]$ curl -h all | ||
+ | Usage: curl [options...] < | ||
+ | | ||
+ | | ||
+ | | ||
+ | -a, --append | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | -E, --cert < | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | -K, --config < | ||
+ | | ||
+ | | ||
+ | -C, --continue-at < | ||
+ | -b, --cookie < | ||
+ | -c, --cookie-jar < | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | -d, --data < | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | -q, --disable | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | -D, --dump-header < | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | -f, --fail | ||
+ | | ||
+ | | ||
+ | | ||
+ | -F, --form < | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | -P, --ftp-port < | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | -G, --get Put the post data in the URL and use GET | ||
+ | -g, --globoff | ||
+ | | ||
+ | | ||
+ | -I, --head | ||
+ | -H, --header < | ||
+ | -h, --help < | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | -0, --http1.0 | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | -i, --include | ||
+ | -k, --insecure | ||
+ | | ||
+ | -4, --ipv4 | ||
+ | -6, --ipv6 | ||
+ | | ||
+ | -j, --junk-session-cookies Ignore session cookies read from file | ||
+ | | ||
+ | --key < | ||
+ | | ||
+ | --krb < | ||
+ | | ||
+ | | ||
+ | -l, --list-only | ||
+ | | ||
+ | -L, --location | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | -M, --manual | ||
+ | | ||
+ | | ||
+ | -m, --max-time < | ||
+ | | ||
+ | | ||
+ | -n, --netrc | ||
+ | | ||
+ | | ||
+ | -:, --next | ||
+ | | ||
+ | -N, --no-buffer | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | -o, --output < | ||
+ | | ||
+ | -Z, --parallel | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | -#, --progress-bar | ||
+ | | ||
+ | | ||
+ | | ||
+ | -x, --proxy [protocol:// | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | -U, --proxy-user < | ||
+ | | ||
+ | -p, --proxytunnel | ||
+ | | ||
+ | -Q, --quote < | ||
+ | | ||
+ | -r, --range < | ||
+ | | ||
+ | | ||
+ | -e, --referer < | ||
+ | -J, --remote-header-name Use the header-provided filename | ||
+ | -O, --remote-name | ||
+ | | ||
+ | -R, --remote-time | ||
+ | | ||
+ | -X, --request < | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | -S, --show-error | ||
+ | -s, --silent | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | -Y, --speed-limit < | ||
+ | -y, --speed-time < | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | -2, --sslv2 | ||
+ | -3, --sslv3 | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | -t, --telnet-option < | ||
+ | | ||
+ | | ||
+ | -z, --time-cond < | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | -1, --tlsv1 | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | -T, --upload-file < | ||
+ | --url < | ||
+ | -B, --use-ascii | ||
+ | -u, --user < | ||
+ | -A, --user-agent < | ||
+ | -v, --verbose | ||
+ | -V, --version | ||
+ | -w, --write-out < | ||
+ | | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | ===== 失敗した続きからレジュームダウンロード (Resumed transfer) [-C, --continue-at < | ||
+ | 公式: [[https:// | ||
+ | <WRAP color_term> | ||
+ | <WRAP color_command>< | ||
+ | <b class=GRN> | ||
+ | </ | ||
+ | <WRAP color_result>< | ||
+ | % Total % Received % Xferd Average Speed | ||
+ | | ||
+ | | ||
+ | curl: (56) OpenSSL SSL_read: 接続が相手からリセットされました, | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | ダウンロードに失敗したバイトの続きをレジュームダウンロードする🤤\\ | ||
+ | <WRAP color_term> | ||
+ | <WRAP color_command>< | ||
+ | <b class=GRN> | ||
+ | </ | ||
+ | <WRAP color_result>< | ||
+ | ** Resuming transfer from byte position 548797494 | ||
+ | % Total % Received % Xferd Average Speed | ||
+ | | ||
+ | 100 24.9M 100 24.9M 0 | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | ==== 公式マニュアル ==== | ||
+ | <WRAP round tip 90%> | ||
+ | **-C, --continue-at < | ||
+ | |||
+ | 指定されたオフセットで以前のファイル転送を続行/ | ||
+ | |||
+ | 「-C -」を使用して、curl に転送を再開する場所/ | ||
+ | |||
+ | [[https:// | ||
+ | |||
+ | 例:\\ | ||
+ | curl -C - https:// | ||
+ | カール -C 400 https:// | ||
+ | |||
+ | [[https:// | ||
+ | |||
+ | </ | ||
+ | |||
+ | ==== curl: option -LOC: expected a proper numerical parameter が発生する😱 ==== | ||
+ | <WRAP round important 90%> | ||
+ | < | ||
+ | <WRAP color_term> | ||
+ | <WRAP color_mincode>< | ||
+ | expected a proper numerical parameter | ||
+ | 適切な数値パラメータが必要です | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | <WRAP color_term> | ||
+ | <WRAP color_command>< | ||
+ | <b class=GRN> | ||
+ | </ | ||
+ | <WRAP color_result>< | ||
+ | curl: option -LOC: expected a proper numerical parameter | ||
+ | curl: try 'curl --help' | ||
+ | </ | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | < | ||
+ | <WRAP color_term> | ||
+ | <WRAP color_command>< | ||
+ | <b class=GRN> | ||
+ | </ | ||
+ | <WRAP color_result>< | ||
+ | ** Resuming transfer from byte position 548797494 | ||
+ | % Total % Received % Xferd Average Speed | ||
+ | | ||
+ | 100 24.9M 100 24.9M 0 | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | < | ||
+ | <WRAP color_term> | ||
+ | <WRAP color_command>< | ||
+ | <b class=GRN> | ||
+ | </ | ||
+ | <WRAP color_result>< | ||
+ | ** Resuming transfer from byte position 548797494 | ||
+ | % Total % Received % Xferd Average Speed | ||
+ | | ||
+ | 100 24.9M 100 24.9M 0 | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | ===== SourceForge.net を curl で取得する方法 ===== | ||
+ | **SourceForge.net** にあるプロジェクトである [[https:// | ||
+ | **SourceForge.net** 公式の文献として存在しているかは未確認であるため、SourceForge.net の仕様が変わるとこの方法は通用しなくなるかもしれませんのでご了承ください。\\ | ||
+ | |||
+ | 例えば、以下のファイルをダウンロードしたいとする。\\ | ||
+ | [[https:// | ||
+ | ブラウザーでは上記のような階層 (**open-jtalk** プロジェクトの **/Open JTalk/ | ||
<WRAP prewrap 100%> | <WRAP prewrap 100%> | ||
< | < | ||
- | $ sudo dnf install | + | $ curl -LO https:// |
</ | </ | ||
</ | </ | ||
+ | **%%https:// | ||
+ | |||
+ | **SourceForge.net** のシステムは優秀ですね😊\\ | ||
+ | |||
+ | 最終リリースのものをダウンロードしたい場合は以下のように記述することもできる。\\ | ||
+ | <WRAP prewrap 100%> | ||
+ | < | ||
+ | $ curl -LO https:// | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | ===== 何が起きていて失敗しているかわからないときの [-I, --head / -v, --verbose] ===== | ||
+ | HTTP レスポンスヘッダーのみを表示したい場合。\\ | ||
+ | <WRAP prewrap 100%> | ||
+ | < | ||
+ | $ curl -LI https:// | ||
+ | </ | ||
+ | </ | ||
+ | <WRAP prewrap 100% # | ||
+ | < | ||
+ | HTTP/1.1 301 Moved Permanently | ||
+ | Server: nginx | ||
+ | Date: Sun, 13 Sep 2020 12:58:11 GMT | ||
+ | Content-Type: | ||
+ | Connection: keep-alive | ||
+ | Pragma: no-cache | ||
+ | Cache-Control: | ||
+ | X-UA-Compatible: | ||
+ | X-Frame-Options: | ||
+ | Content-Security-Policy: | ||
+ | Set-Cookie: VISITOR=03d62803-d938-46db-af08-aff943562899; | ||
+ | Location: https:// | ||
+ | X-Content-Type-Options: | ||
+ | Strict-Transport-Security: | ||
+ | |||
+ | HTTP/1.1 302 Found | ||
+ | Server: nginx | ||
+ | Date: Sun, 13 Sep 2020 12:58:12 GMT | ||
+ | Content-Type: | ||
+ | Connection: keep-alive | ||
+ | Pragma: no-cache | ||
+ | Cache-Control: | ||
+ | X-UA-Compatible: | ||
+ | X-Frame-Options: | ||
+ | Content-Security-Policy: | ||
+ | Set-Cookie: VISITOR=607e89b7-be89-4f4d-b673-8d9aefcd78be; | ||
+ | Location: https:// | ||
+ | X-Content-Type-Options: | ||
+ | Strict-Transport-Security: | ||
+ | |||
+ | HTTP/1.1 302 Found | ||
+ | Server: nginx | ||
+ | Date: Sun, 13 Sep 2020 12:58:13 GMT | ||
+ | Content-Type: | ||
+ | Connection: keep-alive | ||
+ | Content-Disposition: | ||
+ | Set-Cookie: sf_mirror_attempt=open-jtalk: | ||
+ | Location: https:// | ||
+ | |||
+ | HTTP/1.1 200 OK | ||
+ | Date: Sun, 13 Sep 2020 12:58:13 GMT | ||
+ | Server: Apache/ | ||
+ | Last-Modified: | ||
+ | ETag: " | ||
+ | Accept-Ranges: | ||
+ | Content-Length: | ||
+ | Content-Type: | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | **curl** が行っている操作を、より詳細に表示するように指定できる。\\ | ||
+ | <WRAP prewrap 100%> | ||
+ | < | ||
+ | $ curl -LOv https:// | ||
+ | </ | ||
+ | </ | ||
+ | <WRAP prewrap 100% # | ||
+ | < | ||
+ | % Total % Received % Xferd Average Speed | ||
+ | | ||
+ | 0 | ||
+ | * TCP_NODELAY set | ||
+ | 0 | ||
+ | * schannel: SSL/TLS connection with sourceforge.net port 443 (step 1/3) | ||
+ | * schannel: checking server certificate revocation | ||
+ | * schannel: sending initial handshake data: sending 186 bytes... | ||
+ | * schannel: sent initial handshake data: sent 186 bytes | ||
+ | * schannel: SSL/TLS connection with sourceforge.net port 443 (step 2/3) | ||
+ | * schannel: failed to receive handshake, need more data | ||
+ | * schannel: SSL/TLS connection with sourceforge.net port 443 (step 2/3) | ||
+ | * schannel: encrypted data got 2610 | ||
+ | * schannel: encrypted data buffer: offset 2610 length 4096 | ||
+ | * schannel: sending next handshake data: sending 93 bytes... | ||
+ | * schannel: SSL/TLS connection with sourceforge.net port 443 (step 2/3) | ||
+ | * schannel: encrypted data got 51 | ||
+ | * schannel: encrypted data buffer: offset 51 length 4096 | ||
+ | * schannel: SSL/TLS handshake complete | ||
+ | * schannel: SSL/TLS connection with sourceforge.net port 443 (step 3/3) | ||
+ | * schannel: stored credential handle in session cache | ||
+ | > GET / | ||
+ | > Host: sourceforge.net | ||
+ | > User-Agent: curl/7.55.1 | ||
+ | > Accept: */* | ||
+ | > | ||
+ | * schannel: client wants to read 102400 bytes | ||
+ | * schannel: encdata_buffer resized 103424 | ||
+ | * schannel: encrypted data buffer: offset 0 length 103424 | ||
+ | * schannel: encrypted data got 14600 | ||
+ | * schannel: encrypted data buffer: offset 14600 length 103424 | ||
+ | * schannel: failed to decrypt data, need more data | ||
+ | * schannel: schannel_recv cleanup | ||
+ | * schannel: client wants to read 102400 bytes | ||
+ | * schannel: encrypted data buffer: offset 14600 length 103424 | ||
+ | * schannel: encrypted data got 9314 | ||
+ | * schannel: encrypted data buffer: offset 23914 length 103424 | ||
+ | * schannel: decrypted data length: 16384 | ||
+ | * schannel: decrypted data added: 16384 | ||
+ | * schannel: decrypted data cached: offset 16384 length 102400 | ||
+ | * schannel: encrypted data length: 7501 | ||
+ | * schannel: encrypted data cached: offset 7501 length 103424 | ||
+ | * schannel: decrypted data length: 7472 | ||
+ | * schannel: decrypted data added: 7472 | ||
+ | * schannel: decrypted data cached: offset 23856 length 102400 | ||
+ | * schannel: encrypted data buffer: offset 0 length 103424 | ||
+ | * schannel: decrypted data buffer: offset 23856 length 102400 | ||
+ | * schannel: schannel_recv cleanup | ||
+ | * schannel: decrypted data returned 23856 | ||
+ | * schannel: decrypted data buffer: offset 0 length 102400 | ||
+ | < HTTP/1.1 301 Moved Permanently | ||
+ | < Server: nginx | ||
+ | < Date: Sun, 13 Sep 2020 12:40:28 GMT | ||
+ | < Content-Type: | ||
+ | < Content-Length: | ||
+ | < Connection: keep-alive | ||
+ | < Pragma: no-cache | ||
+ | < Cache-Control: | ||
+ | < X-UA-Compatible: | ||
+ | < X-Frame-Options: | ||
+ | < Content-Security-Policy: | ||
+ | < Set-Cookie: VISITOR=ac83a66e-c2de-49f4-84f7-db630e784d12; | ||
+ | < Location: https:// | ||
+ | < X-Content-Type-Options: | ||
+ | < Strict-Transport-Security: | ||
+ | < | ||
+ | * Ignoring the response-body | ||
+ | { [23227 bytes data] | ||
+ | 100 23227 100 23227 0 | ||
+ | * Connection #0 to host sourceforge.net left intact | ||
+ | * Issue another request to this URL: ' | ||
+ | * Found bundle for host sourceforge.net: | ||
+ | * Re-using existing connection! (#0) with host sourceforge.net | ||
+ | * Connected to sourceforge.net (216.105.38.13) port 443 (#0) | ||
+ | > GET / | ||
+ | > Host: sourceforge.net | ||
+ | > User-Agent: curl/7.55.1 | ||
+ | > Accept: */* | ||
+ | > | ||
+ | * schannel: client wants to read 102400 bytes | ||
+ | * schannel: encrypted data buffer: offset 0 length 103424 | ||
+ | * schannel: encrypted data got 20793 | ||
+ | * schannel: encrypted data buffer: offset 20793 length 103424 | ||
+ | * schannel: decrypted data length: 16384 | ||
+ | * schannel: decrypted data added: 16384 | ||
+ | * schannel: decrypted data cached: offset 16384 length 102400 | ||
+ | * schannel: encrypted data length: 4380 | ||
+ | * schannel: encrypted data cached: offset 4380 length 103424 | ||
+ | * schannel: failed to decrypt data, need more data | ||
+ | * schannel: schannel_recv cleanup | ||
+ | * schannel: decrypted data returned 16384 | ||
+ | * schannel: decrypted data buffer: offset 0 length 102400 | ||
+ | < HTTP/1.1 302 Found | ||
+ | < Server: nginx | ||
+ | < Date: Sun, 13 Sep 2020 12:40:28 GMT | ||
+ | < Content-Type: | ||
+ | < Content-Length: | ||
+ | < Connection: keep-alive | ||
+ | < Pragma: no-cache | ||
+ | < Cache-Control: | ||
+ | < X-UA-Compatible: | ||
+ | < X-Frame-Options: | ||
+ | < Content-Security-Policy: | ||
+ | < Set-Cookie: VISITOR=ceaebdca-1016-4e18-bdc6-67cba423530e; | ||
+ | < Location: https:// | ||
+ | < X-Content-Type-Options: | ||
+ | < Strict-Transport-Security: | ||
+ | < | ||
+ | * Ignoring the response-body | ||
+ | { [15694 bytes data] | ||
+ | * schannel: client wants to read 7738 bytes | ||
+ | * schannel: encrypted data buffer: offset 4380 length 103424 | ||
+ | * schannel: encrypted data got 3387 | ||
+ | * schannel: encrypted data buffer: offset 7767 length 103424 | ||
+ | * schannel: decrypted data length: 7738 | ||
+ | * schannel: decrypted data added: 7738 | ||
+ | * schannel: decrypted data cached: offset 7738 length 102400 | ||
+ | * schannel: encrypted data buffer: offset 0 length 103424 | ||
+ | * schannel: decrypted data buffer: offset 7738 length 102400 | ||
+ | * schannel: schannel_recv cleanup | ||
+ | * schannel: decrypted data returned 7738 | ||
+ | * schannel: decrypted data buffer: offset 0 length 102400 | ||
+ | { [7738 bytes data] | ||
+ | 100 23432 100 23432 0 | ||
+ | * Connection #0 to host sourceforge.net left intact | ||
+ | * Issue another request to this URL: ' | ||
+ | * | ||
+ | * TCP_NODELAY set | ||
+ | * Connected to downloads.sourceforge.net (216.105.38.13) port 443 (#1) | ||
+ | 0 | ||
+ | * schannel: checking server certificate revocation | ||
+ | * schannel: sending initial handshake data: sending 196 bytes... | ||
+ | * schannel: sent initial handshake data: sent 196 bytes | ||
+ | * schannel: SSL/TLS connection with downloads.sourceforge.net port 443 (step 2/3) | ||
+ | * schannel: failed to receive handshake, need more data | ||
+ | * schannel: SSL/TLS connection with downloads.sourceforge.net port 443 (step 2/3) | ||
+ | * schannel: encrypted data got 2611 | ||
+ | * schannel: encrypted data buffer: offset 2611 length 4096 | ||
+ | * schannel: sending next handshake data: sending 93 bytes... | ||
+ | * schannel: SSL/TLS connection with downloads.sourceforge.net port 443 (step 2/3) | ||
+ | * schannel: encrypted data got 51 | ||
+ | * schannel: encrypted data buffer: offset 51 length 4096 | ||
+ | * schannel: SSL/TLS handshake complete | ||
+ | * schannel: SSL/TLS connection with downloads.sourceforge.net port 443 (step 3/3) | ||
+ | * schannel: stored credential handle in session cache | ||
+ | > GET / | ||
+ | > Host: downloads.sourceforge.net | ||
+ | > User-Agent: curl/7.55.1 | ||
+ | > Accept: */* | ||
+ | > | ||
+ | * schannel: client wants to read 102400 bytes | ||
+ | * schannel: encdata_buffer resized 103424 | ||
+ | * schannel: encrypted data buffer: offset 0 length 103424 | ||
+ | * schannel: encrypted data got 920 | ||
+ | * schannel: encrypted data buffer: offset 920 length 103424 | ||
+ | * schannel: decrypted data length: 891 | ||
+ | * schannel: decrypted data added: 891 | ||
+ | * schannel: decrypted data cached: offset 891 length 102400 | ||
+ | * schannel: encrypted data buffer: offset 0 length 103424 | ||
+ | * schannel: decrypted data buffer: offset 891 length 102400 | ||
+ | * schannel: schannel_recv cleanup | ||
+ | * schannel: decrypted data returned 891 | ||
+ | * schannel: decrypted data buffer: offset 0 length 102400 | ||
+ | < HTTP/1.1 302 Found | ||
+ | < Server: nginx | ||
+ | < Date: Sun, 13 Sep 2020 12:40:30 GMT | ||
+ | < Content-Type: | ||
+ | < Content-Length: | ||
+ | < Connection: keep-alive | ||
+ | < Content-Disposition: | ||
+ | < Set-Cookie: sf_mirror_attempt=open-jtalk: | ||
+ | < Location: https:// | ||
+ | < | ||
+ | * Ignoring the response-body | ||
+ | { [389 bytes data] | ||
+ | 100 | ||
+ | * Connection #1 to host downloads.sourceforge.net left intact | ||
+ | * Issue another request to this URL: ' | ||
+ | * | ||
+ | * TCP_NODELAY set | ||
+ | * Connected to jaist.dl.sourceforge.net (150.65.7.130) port 443 (#2) | ||
+ | * schannel: SSL/TLS connection with jaist.dl.sourceforge.net port 443 (step 1/3) | ||
+ | * schannel: checking server certificate revocation | ||
+ | * schannel: sending initial handshake data: sending 195 bytes... | ||
+ | * schannel: sent initial handshake data: sent 195 bytes | ||
+ | * schannel: SSL/TLS connection with jaist.dl.sourceforge.net port 443 (step 2/3) | ||
+ | * schannel: failed to receive handshake, need more data | ||
+ | * schannel: SSL/TLS connection with jaist.dl.sourceforge.net port 443 (step 2/3) | ||
+ | * schannel: encrypted data got 2996 | ||
+ | * schannel: encrypted data buffer: offset 2996 length 4096 | ||
+ | * schannel: sending next handshake data: sending 126 bytes... | ||
+ | 0 | ||
+ | * schannel: encrypted data got 290 | ||
+ | * schannel: encrypted data buffer: offset 290 length 4096 | ||
+ | * schannel: SSL/TLS handshake complete | ||
+ | * schannel: SSL/TLS connection with jaist.dl.sourceforge.net port 443 (step 3/3) | ||
+ | * schannel: stored credential handle in session cache | ||
+ | > GET / | ||
+ | > Host: jaist.dl.sourceforge.net | ||
+ | > User-Agent: curl/7.55.1 | ||
+ | > Accept: */* | ||
+ | > | ||
+ | * schannel: client wants to read 102400 bytes | ||
+ | * schannel: encdata_buffer resized 103424 | ||
+ | * schannel: encrypted data buffer: offset 0 length 103424 | ||
+ | * schannel: encrypted data got 8760 | ||
+ | * schannel: encrypted data buffer: offset 8760 length 103424 | ||
+ | * schannel: decrypted data length: 260 | ||
+ | * schannel: decrypted data added: 260 | ||
+ | * schannel: decrypted data cached: offset 260 length 102400 | ||
+ | * schannel: encrypted data length: 8471 | ||
+ | * schannel: encrypted data cached: offset 8471 length 103424 | ||
+ | * schannel: failed to decrypt data, need more data | ||
+ | * schannel: schannel_recv cleanup | ||
+ | * schannel: decrypted data returned 260 | ||
+ | * schannel: decrypted data buffer: offset 0 length 102400 | ||
+ | < HTTP/1.1 200 OK | ||
+ | < Date: Sun, 13 Sep 2020 12:40:30 GMT | ||
+ | < Server: Apache/ | ||
+ | < Last-Modified: | ||
+ | < ETag: " | ||
+ | < Accept-Ranges: | ||
+ | < Content-Length: | ||
+ | < Content-Type: | ||
+ | < | ||
+ | * schannel: client wants to read 102400 bytes | ||
+ | * schannel: encrypted data buffer: offset 8471 length 103424 | ||
+ | * schannel: encrypted data got 46720 | ||
+ | * schannel: encrypted data buffer: offset 55191 length 103424 | ||
+ | * schannel: decrypted data length: 16384 | ||
+ | * schannel: decrypted data added: 16384 | ||
+ | * schannel: decrypted data cached: offset 16384 length 102400 | ||
+ | * schannel: encrypted data length: 38778 | ||
+ | * schannel: encrypted data cached: offset 38778 length 103424 | ||
+ | * schannel: decrypted data length: 16384 | ||
+ | * schannel: decrypted data added: 16384 | ||
+ | * schannel: decrypted data cached: offset 32768 length 102400 | ||
+ | * schannel: encrypted data length: 22365 | ||
+ | * schannel: encrypted data cached: offset 22365 length 103424 | ||
+ | * schannel: decrypted data length: 16384 | ||
+ | * schannel: decrypted data added: 16384 | ||
+ | * schannel: decrypted data cached: offset 49152 length 102400 | ||
+ | * schannel: encrypted data length: 5952 | ||
+ | * schannel: encrypted data cached: offset 5952 length 103424 | ||
+ | * schannel: failed to decrypt data, need more data | ||
+ | * schannel: schannel_recv cleanup | ||
+ | * schannel: decrypted data returned 49152 | ||
+ | * schannel: decrypted data buffer: offset 0 length 102400 | ||
+ | { [49152 bytes data] | ||
+ | ... | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | ===== 参考文献 ===== | ||
+ | [[https:// | ||
+ | [[https:// | ||
+ | [[https:// | ||