That's because you are not attaching the zip file. You need something like 
(empty lines are significant):

MIME-Version: 1.0
Content-type: multipart/mixed; boundary="simple boundary"
Content-Transfer-Encoding: binary
...

arbitrary text

----simple boundary
Content-type:  APPLICATION/ZIP
CONTENT-DISPOSITION: ATTACHMENT; FILENAME=TEST.ZIP
Content-Transfer-Encoding: binary

zipped file

--
Shmuel (Seymour J.) Metz
http://mason.gmu.edu/~smetz3

________________________________________
From: IBM Mainframe Discussion List [IBM-MAIN@LISTSERV.UA.EDU] on behalf of 
Sasso, Len [0000039db7f8412a-dmarc-requ...@listserv.ua.edu]
Sent: Wednesday, April 27, 2022 12:28 PM
To: IBM-MAIN@LISTSERV.UA.EDU
Subject: Re: Send an email with a Zip file as an attachment?

If I specify either:

CONTENT-TYPE: APPLICATION/ZIP; BOUNDARY="SIMPLE BOUNDARY"
CONTENT-DISPOSITION: ATTACHMENT; FILENAME=TEST.ZIP
CONTENT-TRANSFER-ENCODING: BINARY

or

CONTENT-TYPE: APPLICATION/OCTET-STREAM; BOUNDARY="SIMPLE BOUNDARY"
CONTENT-DISPOSITION: ATTACHMENT; FILENAME=TEST.ZIP
CONTENT-TRANSFER-ENCODING: BINARY


I receive the message below from 7-Zip, when I attempt to extract the file:


Can not open file "TEST.ZIP" as archive.



Thank You and Please Be Safe!

Len Sasso
Systems Administrator Senior
CSRA, A General Dynamics Information Technology Company
327 Columbia TPKE
Rensselaer, NY 12144

TEAM: Together Everyone Achieves More

Office Hours: M-F  7 AM - 3:45 PM

Vacation:

Phone: (518) 257-4209
Cell: (518) 894-0879
Fax: (518) 257-4300
len.sa...@gdit.com
URL: 
https://nam11.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.gdit.com%2F&amp;data=05%7C01%7Csmetz3%40gmu.edu%7C4698218f41ca408f9d7408da286b067e%7C9e857255df574c47a0c00546460380cb%7C0%7C0%7C637866737375460987%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&amp;sdata=Xxrt1GOJdVxJ7OInTuiNyY29ESkE2JAsWxjNhTrLsFg%3D&amp;reserved=0<https://nam11.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.gdit.com%2F&amp;data=05%7C01%7Csmetz3%40gmu.edu%7C4698218f41ca408f9d7408da286b067e%7C9e857255df574c47a0c00546460380cb%7C0%7C0%7C637866737375460987%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&amp;sdata=Xxrt1GOJdVxJ7OInTuiNyY29ESkE2JAsWxjNhTrLsFg%3D&amp;reserved=0>




________________________________
From: IBM Mainframe Discussion List <IBM-MAIN@LISTSERV.UA.EDU> on behalf of 
Paul Gilmartin <0000000433f07816-dmarc-requ...@listserv.ua.edu>
Sent: Wednesday, April 27, 2022 12:21 PM
To: IBM-MAIN@LISTSERV.UA.EDU <IBM-MAIN@LISTSERV.UA.EDU>
Subject: Re: Send an email with a Zip file as an attachment?



 [External: Use caution with links & attachments]

On Wed, 27 Apr 2022 15:48:04 +0000, Sasso, Len  wrote:

>When I tried to open it with 7-Zip I received the following message:
>
>       Can not open file "abc.zip" as archive.
>
Is EBCDIC the problem?

On Wed, 27 Apr 2022 10:14:52 -0500, Carmen Vitullo wrote:

>I have an example, not attaching a zip file - do you have a product like
>PKZIP on the mainframe?
>

"jar"

Protect the .zip file with "uuencode -m", or (not SYSIN-safe) TSO TRANSMIT.

#! /bin/sh -x
# Run thsi script or paste into uudecode.
# Safest to extract in an empty directory.
uudecode -i <<{endmime}

( Comments hardly matter. )

begin-base64 644 makesea.zip
UEsDBBQAAAAIAKyVKlRzne3JKwEAAKoBAAAHABwAbWFrZXNlYVVUCQADNOHcYaer3WF1eAsAAQT1
AQAABAAAAABFj8FOwzAQRO/+iiEJSkuVVL2WIqQWlRM9UHHj4jibxmpiR/YGGlX5dxwB6nX1ZmZf
fIdloc3S11hcRIwXq9Z4k2eCp6bK6MJOKtZGnyCdqrX+ItgKySoP8Pbj9TjRAwpH8gxrYKzJOutY
Fg2hk1wb2VIuxP7wlMxCJyOzATo1tgBizLCVYdp3pHSl1TPmglRtkVxXcfywHDGfqF1D0qDvkC5T
SFPiu9ZMvpNqqu6cNlwhvfcpok8R34yyyei9N+Daa3jldMewLvzlmRBSFn1fkrIlTTpHWZFnhOuf
dkDCHKjteECpHSm2bsjFfwiZxmZzJVO2uqVRiBl2tm3JsEctXdkMaCUzuTx4iX//y2NYJfNb0E6q
iyhZRSOi5Lo/rDPPpTZjFNTFrToSP1BLAQIeAxQAAAAIAKyVKlRzne3JKwEAAKoBAAAHABgAAAAA
AAEAAADtgQAAAABtYWtlc2VhVVQFAAM04dxhdXgLAAEE9QEAAAQAAAAAUEsFBgAAAAABAAEATQAA
AGwBAAAAAA==
====
{endmime}

--
gil

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN

Reply via email to