1ZIP_FOPEN_ENCRYPTED(3)     Library Functions Manual     ZIP_FOPEN_ENCRYPTED(3)
2
3
4

NAME

6       zip_fopen_encrypted  ,  -  .Nm zip_fopen_index_encrypted open encrypted
7       file in zip archive for reading
8

LIBRARY

10       libzip (-lzip)
11

SYNOPSIS

13       #include <zip.h>
14
15       struct zip_file * zip_fopen_encrypted(struct zip *archive,  const  char
16       *fname, int flags, const char *password);
17
18       struct   zip_file   *  zip_fopen_index_encrypted(struct  zip  *archive,
19       zip_uint64_t index, int flags, const char *password);
20

DESCRIPTION

22       The zip_fopen_encrypted function opens the encrypted file name fname in
23       archive  using  the password given in the password argument.  The flags
24       argument are the same as for zip_fopen(3).
25
26       The zip_fopen_index_encrypted  function  opens  the  file  at  position
27       index,  see  zip_fopen_index(3).   These functions are called automati‐
28       cally by zip_fopen(3); you only need to call them if you want to  spec‐
29       ify a non-default password (see zip_set_default_password(3) ).
30

RETURN VALUES

32       Upon successful completion, a
33
34       struct  zip_file  pointer is returned.  Otherwise, NULL is returned and
35       the error code in archive is set to indicate the error.
36

ERRORS

38              [ZIP_ER_NOPASSWD]     No password was provided.
39
40       The function zip_fopen_encrypted may also fail and set for any  of  the
41       errors specified for the routine zip_fopen(3).
42
43       The function zip_fopen_index_encrypted may also fail and set for any of
44       the errors specified for the routine zip_fopen_index(3).
45

SEE ALSO

47       libzip(3),       zip_fclose(3),       zip_fopen(3),       zip_fread(3),
48       zip_get_num_entries(3), zip_name_locate(3)
49

AUTHORS

51       Dieter Baron <dillo@giga.or.at> and Thomas Klausner <tk@giga.or.at>
52
53
54
55NiH                            February 14, 2011        ZIP_FOPEN_ENCRYPTED(3)
Impressum