On Fri, 28 Oct 2016 20:15:42 -0700, Alan Young wrote:
>Well, on linux/unix a command line of curl -O downloads a file or page
>in binary mode.
>
I see in the curl docs for z/OS (and others):
.IP "-O, --remote-name"
Write output to a local file named like the remote file we get. (Only the
file
part of the remote file is used, the path is cut off.)
... no mention of binary.
>What curl command line are you issuing?
>
More detail, with a specific path, not an unreleased APAR. On Solaris:
user@SunOS.5.11: proxy curl ftp://cbttape.org/pub/zips/CBT776.zip | cksum
% Total% Received % Xferd Average Speed TimeTime Time Current
Dload Upload Total SpentLeft Speed
100 116k 100 116k0 0 95265 0 0:00:01 0:00:01 --:--:-- 95500
387018231 119280
user@SunOS.5.11: proxy curl -sS ftp://cbttape.org/pub/zips/CBT776.zip | jar -tv
35147 Tue Jan 08 20:40:56 MST 2008 gpl-3.0.txt
86392 Tue Dec 25 17:30:10 MST 2007 recv390.c
39936 Tue Dec 25 17:30:26 MST 2007 RECV390.exe
11972 Sun Apr 08 00:55:28 MDT 2001 recv390V1R1M4.html
31300 Mon Jan 28 14:46:54 MST 2008 recv390v1r1m6.html
0 Mon Jan 28 18:33:12 MST 2008 V1R1M4/
896 Sat Apr 07 18:55:22 MDT 2001 V1R1M4/makefile
67050 Sat Apr 07 18:55:24 MDT 2001 V1R1M4/recv390.c
61440 Sat Apr 07 18:55:26 MDT 2001 V1R1M4/RECV390.EXE
11972 Sat Apr 07 18:55:28 MDT 2001 V1R1M4/recv390.html
On z/OS:
user@OS/390.25.00: proxy curl ftp://cbttape.org/pub/zips/CBT776.zip | cksum
% Total% Received % Xferd Average Speed TimeTime Time Current
Dload Upload Total SpentLeft Speed
100 116k 100 116k0 0 55602 0 0:00:02 0:00:02 --:--:-- 98k
3151097663 119280
... the size agrees; the checksum disagrees; no point in trying
to extract.
>-Original Message-
>>From: Paul Gilmartin
>>Sent: Oct 28, 2016 6:05 PM
>>To: IBM-MAIN@LISTSERV.UA.EDU
>>Subject: curl is Rocket science.
>>
>>Trying to use curl:
>>
>>user@OS/390.25.00: ls -lTHE /team/rocket/cURL/bin/curl
>>- untaggedT=off -rwxr-xr-x --s- 1 OMVSKERN SYS1 17735680 Feb
>>11 2016 /team/rocket/cURL/bin/curl
>>
>>user@OS/390.25.00: /team/rocket/cURL/bin/curl --version
>>curl 7.42.1 (i370-ibm-openedition) libcurl/7.42.1 OpenSSL/1.0.2c zlib/1.2.8
>>iconv libssh2/1.4.3 nghttp2/1.0.1
>>Protocols: dict file ftp ftps gopher http https imap imaps pop3 pop3s rtsp
>>scp sftp smb smbs smtp smtps telnet tftp
>>Features: IPv6 Largefile NTLM NTLM_WB SSL libz CharConv TLS-SRP HTTP2
>>UnixSockets Metalink
>>
>>... to download an IBM fixtest, I got junk:
>>user@OS/390.25.00: cat AA51501.HIF7P02 | od -tx1 | head
>>00EF EF 85 AB 85 8D EB 85 85 77 C9 77 2C C9 B8 4F
>>
>>... but with *two* successive EBCDIC-to-ASCII translations, success:
>>user@OS/390.25.00: cat AA51501.HIF7P02 | e2a | e2a | od -tx1 | head
>>004E 4E C1 D7 C1 D9 4D C1 C1 F5 F1 F5 F0 F1 5D 40
>> + + A P A R ( A A 5 1 5 0 1 )
>>
>>WTF!? Surely this isn't working as designed.
>>
>>I hate EBCDIC!
-- gil
--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN