{
    "mode": "man",
    "parameter": "funzip",
    "section": "1",
    "url": "https://www.chedong.com/phpMan.php/man/funzip/1/json",
    "generated": "2026-05-30T05:09:48Z",
    "synopsis": "funzip [-password] [input[.zip|.gz]]",
    "sections": {
        "NAME": {
            "content": "funzip - filter for extracting from a ZIP archive in a pipe\n",
            "subsections": []
        },
        "SYNOPSIS": {
            "content": "funzip [-password] [input[.zip|.gz]]\n",
            "subsections": []
        },
        "ARGUMENTS": {
            "content": "[-password]\nOptional  password to be used if ZIP archive is encrypted.  Decryption may not be sup‐\nported at some sites.  See DESCRIPTION for more details.\n\n[input[.zip|.gz]]\nOptional input archive file specification. See DESCRIPTION for details.\n",
            "subsections": []
        },
        "DESCRIPTION": {
            "content": "funzip without a file argument acts as a filter; that is, it assumes that a ZIP archive (or a\ngzip'd(1) file) is being piped into standard input, and it extracts the first member from the\narchive to stdout.  When stdin comes from a tty device, funzip assumes that this cannot be  a\nstream  of (binary) compressed data and shows a short help text, instead.  If there is a file\nargument, then input is read from the specified file instead of from stdin.\n\nA password for encrypted zip files can be specified on the command line (preceding  the  file\nname,  if  any) by prefixing the password with a dash.  Note that this constitutes a security\nrisk on many systems; currently running processes  are  often  visible  via  simple  commands\n(e.g.,  ps(1) under Unix), and command-line histories can be read.  If the first entry of the\nzip file is encrypted and no password is specified on the command  line,  then  the  user  is\nprompted for a password and the password is not echoed on the console.\n\nGiven the limitation on single-member extraction, funzip is most useful in conjunction with a\nsecondary archiver program such as tar(1).  The following section includes an example  illus‐\ntrating this usage in the case of disk backups to tape.\n",
            "subsections": []
        },
        "EXAMPLES": {
            "content": "To  use  funzip  to extract the first member file of the archive test.zip and to pipe it into\nmore(1):\n\nfunzip test.zip | more\n\nTo use funzip to test the first member file of test.zip (any errors will be reported on stan‐\ndard error):\n\nfunzip test.zip > /dev/null\n\nTo  use zip and funzip in place of compress(1) and zcat(1) (or gzip(1) and gzcat(1)) for tape\nbackups:\n\ntar cf - . | zip -7 | dd of=/dev/nrst0 obs=8k\ndd if=/dev/nrst0 ibs=8k | funzip | tar xf -\n\n(where, for example, nrst0 is a SCSI tape drive).\n",
            "subsections": []
        },
        "BUGS": {
            "content": "When piping an encrypted file into more and allowing funzip to prompt for password, the  ter‐\nminal  may sometimes be reset to a non-echo mode.  This is apparently due to a race condition\nbetween the two programs; funzip changes the terminal mode to non-echo before more reads  its\nstate,  and more then ``restores'' the terminal to this mode before exiting.  To recover, run\nfunzip on the same file but redirect to /dev/null rather than piping into more; after prompt‐\ning again for the password, funzip will reset the terminal properly.\n\nThere is presently no way to extract any member but the first from a ZIP archive.  This would\nbe useful in the case where a ZIP archive is included within another archive.   In  the  case\nwhere the first member is a directory, funzip simply creates the directory and exits.\n\nThe functionality of funzip should be incorporated into unzip itself (future release).\n",
            "subsections": []
        },
        "SEE ALSO": {
            "content": "gzip(1), unzip(1), unzipsfx(1), zip(1), zipcloak(1), zipinfo(1), zipnote(1), zipsplit(1)\n",
            "subsections": []
        },
        "URL": {
            "content": "The Info-ZIP home page is currently at\nhttp://www.info-zip.org/pub/infozip/\nor\nftp://ftp.info-zip.org/pub/infozip/ .\n",
            "subsections": []
        },
        "AUTHOR": {
            "content": "Mark Adler (Info-ZIP)\n\n\n\nInfo-ZIP                                20 April 2009 (v3.95)                              FUNZIP(1)",
            "subsections": []
        }
    },
    "summary": "funzip - filter for extracting from a ZIP archive in a pipe",
    "flags": [],
    "examples": [
        "To  use  funzip  to extract the first member file of the archive test.zip and to pipe it into",
        "more(1):",
        "funzip test.zip | more",
        "To use funzip to test the first member file of test.zip (any errors will be reported on stan‐",
        "dard error):",
        "funzip test.zip > /dev/null",
        "To  use zip and funzip in place of compress(1) and zcat(1) (or gzip(1) and gzcat(1)) for tape",
        "backups:",
        "tar cf - . | zip -7 | dd of=/dev/nrst0 obs=8k",
        "dd if=/dev/nrst0 ibs=8k | funzip | tar xf -",
        "(where, for example, nrst0 is a SCSI tape drive)."
    ],
    "see_also": [
        {
            "name": "gzip",
            "section": "1",
            "url": "https://www.chedong.com/phpMan.php/man/gzip/1/json"
        },
        {
            "name": "unzip",
            "section": "1",
            "url": "https://www.chedong.com/phpMan.php/man/unzip/1/json"
        },
        {
            "name": "unzipsfx",
            "section": "1",
            "url": "https://www.chedong.com/phpMan.php/man/unzipsfx/1/json"
        },
        {
            "name": "zip",
            "section": "1",
            "url": "https://www.chedong.com/phpMan.php/man/zip/1/json"
        },
        {
            "name": "zipcloak",
            "section": "1",
            "url": "https://www.chedong.com/phpMan.php/man/zipcloak/1/json"
        },
        {
            "name": "zipinfo",
            "section": "1",
            "url": "https://www.chedong.com/phpMan.php/man/zipinfo/1/json"
        },
        {
            "name": "zipnote",
            "section": "1",
            "url": "https://www.chedong.com/phpMan.php/man/zipnote/1/json"
        },
        {
            "name": "zipsplit",
            "section": "1",
            "url": "https://www.chedong.com/phpMan.php/man/zipsplit/1/json"
        }
    ]
}