Rizin
unix-like reverse engineering framework and cli tools
|
Go to the source code of this file.
Classes | |
struct | rz_io_zip_uri_const_t |
struct | rz_io_zfo_t |
Typedefs | |
typedef struct rz_io_zip_uri_const_t | RzIOZipConstURI |
typedef struct rz_io_zfo_t | RzIOZipFileObj |
Enumerations | |
enum | RZ_IO_ZIP_ARCHIVE_TYPE { RZ_IO_PARENT_ZIP = 0x0001 , RZ_IO_CHILD_FILE = 0x0002 , RZ_IO_NEW_FILE = 0x0004 , RZ_IO_EXISTING_FILE = 0x0008 , RZ_IO_MODIFIED_FILE = 0x0010 , RZ_IO_DELETED_FILE = 0x0020 } |
Variables | |
static RzIOZipConstURI | ZIP_URIS [] |
static RzIOZipConstURI | ZIP_ALL_URIS [] |
RzIOPlugin | rz_io_plugin_zip |
RZ_API RzLibStruct | rizin_plugin |
typedef struct rz_io_zip_uri_const_t RzIOZipConstURI |
typedef struct rz_io_zfo_t RzIOZipFileObj |
Definition at line 409 of file io_zip.c.
References desc, rz_io_zfo_t::entry, eprintf, files, rz_io_zfo_t::io_backref, rz_io_zfo_t::name, NULL, rz_io_desc_add(), rz_io_desc_new(), rz_io_plugin_zip, rz_io_zip_alloc_zipfileobj(), rz_io_zip_free_zipfileobj(), rz_io_zip_get_files(), rz_list_free(), RZ_LOG_INFO, rz_str_endswith(), rz_str_newf(), strdup(), and ZIP_CREATE.
Referenced by rz_io_zip_open().
Definition at line 376 of file io_zip.c.
References files, name, NULL, RZ_FREE, rz_io_zip_get_files(), rz_list_free(), rz_str_newf(), and rz_str_rchr().
Referenced by rz_io_zip_open().
RzIOZipFileObj* rz_io_zip_alloc_zipfileobj | ( | const char * | archivename, |
const char * | filename, | ||
ut32 | perm, | ||
int | mode, | ||
int | rw | ||
) |
Definition at line 252 of file io_zip.c.
References i, NULL, rz_io_zip_create_new_file(), rz_io_zip_open_archive(), rz_io_zip_slurp_file(), sb, ut64(), zip_close(), zip_get_num_files(), zip_stat_index(), and zip_stat_init().
Referenced by find_apk_binary(), rz_io_zip_open(), and rz_io_zip_open_many().
Definition at line 73 of file io_zip.c.
References i, len, rz_io_zip_uri_const_t::name, NULL, rz_io_zip_has_uri_substr(), and ZIP_URIS.
Referenced by rz_io_zip_plugin_open().
Definition at line 61 of file io_zip.c.
References i, len, rz_io_zip_uri_const_t::name, NULL, rz_io_zip_has_uri_substr(), and ZIP_ALL_URIS.
Referenced by rz_io_zip_plugin_open().
RzIOZipFileObj* rz_io_zip_create_new_file | ( | const char * | archivename, |
const char * | filename, | ||
struct zip_stat * | sb, | ||
ut32 | perm, | ||
int | mode, | ||
int | rw | ||
) |
Definition at line 236 of file io_zip.c.
References rz_io_zfo_t::archivename, rz_io_zfo_t::b, rz_io_zfo_t::entry, rz_io_zfo_t::fd, rz_io_zfo_t::mode, rz_io_zfo_t::name, NULL, rz_io_zfo_t::perm, rz_io_zfo_t::rw, rz_buf_new_with_bytes(), RZ_NEW0, rz_num_rand(), sb, and strdup().
Referenced by rz_io_zip_alloc_zipfileobj().
int rz_io_zip_flush_file | ( | RzIOZipFileObj * | zfo | ) |
Definition at line 188 of file io_zip.c.
References rz_io_zfo_t::archivename, rz_io_zfo_t::b, rz_io_zfo_t::entry, rz_io_zfo_t::mode, rz_io_zfo_t::name, rz_io_zfo_t::perm, rz_io_zfo_t::rw, rz_buf_data(), rz_io_zip_open_archive(), s, autogen_x86imm::tmp, ut64(), zip_add(), zip_close(), zip_name_locate(), zip_replace(), zip_source_buffer(), and zip_source_free().
Referenced by rz_io_zip_free_zipfileobj(), rz_io_zip_resize(), and rz_io_zip_write().
|
static |
Definition at line 223 of file io_zip.c.
References rz_io_zfo_t::b, free(), rz_io_zfo_t::modified, rz_io_zfo_t::name, rz_io_zfo_t::password, rz_buf_free(), and rz_io_zip_flush_file().
Referenced by find_apk_binary(), and rz_io_zip_close().
char* rz_io_zip_get_by_file_idx | ( | const char * | archivename, |
const char * | idx, | ||
ut32 | perm, | ||
int | mode, | ||
int | rw | ||
) |
Definition at line 348 of file io_zip.c.
References i, setup::idx, NULL, rz_io_zip_open_archive(), sb, strdup(), ut64(), zip_close(), zip_get_num_files(), zip_stat_index(), and zip_stat_init().
Referenced by rz_io_zip_open().
Definition at line 160 of file io_zip.c.
References files, free(), i, NULL, rz_io_zip_open_archive(), rz_list_append(), rz_list_newf(), sb, strdup(), ut64(), zip_close(), zip_get_num_files(), zip_stat_index(), and zip_stat_init().
Referenced by find_apk_binary(), find_ipa_binary(), rz_io_zip_open(), and rz_io_zip_open_many().
Definition at line 57 of file io_zip.c.
Referenced by rz_io_zip_check_uri(), and rz_io_zip_check_uri_many().
Definition at line 568 of file io_zip.c.
References rz_io_zfo_t::b, fd, rz_io_t::off, rz_buf_seek(), RZ_BUF_SET, rz_buf_size(), rz_buf_tell(), SEEK_CUR, SEEK_END, SEEK_SET, and ut64().
Definition at line 449 of file io_zip.c.
References rz_io_t::cb_printf, done, rz_io_zfo_t::entry, eprintf, files, find_apk_binary(), find_ipa_binary(), free(), i, rz_io_zfo_t::io_backref, name, rz_io_zfo_t::name, NULL, RZ_FREE, rz_io_desc_free(), rz_io_desc_new(), rz_io_plugin_zip, rz_io_zip_alloc_zipfileobj(), rz_io_zip_get_by_file_idx(), rz_io_zip_get_files(), rz_io_zip_plugin_open(), rz_list_free(), rz_str_newf(), strdup(), autogen_x86imm::tmp, and ZIP_CREATE.
Definition at line 95 of file io_zip.c.
References eprintf, NULL, ZIP_ER_INCONS, ZIP_ER_INVAL, ZIP_ER_NOENT, ZIP_ER_NOZIP, ZIP_ER_OPEN, ZIP_ER_READ, and zip_open().
Referenced by rz_io_zip_alloc_zipfileobj(), rz_io_zip_flush_file(), rz_io_zip_get_by_file_idx(), rz_io_zip_get_files(), and rz_io_zip_slurp_file().
Definition at line 284 of file io_zip.c.
References rz_io_zfo_t::entry, eprintf, free(), rz_io_zfo_t::io_backref, rz_io_zfo_t::name, NULL, rz_io_desc_new(), rz_io_plugin_zip, rz_io_zip_alloc_zipfileobj(), rz_io_zip_get_files(), rz_io_zip_plugin_open(), rz_list_append(), rz_list_free(), rz_list_new(), strdup(), v, and ZIP_CREATE.
Definition at line 85 of file io_zip.c.
References rz_io_zip_check_uri(), and rz_io_zip_check_uri_many().
Referenced by rz_io_zip_open(), and rz_io_zip_open_many().
Definition at line 599 of file io_zip.c.
References rz_io_zfo_t::b, count, fd, NULL, rz_io_t::off, r, RZ_BUF_CUR, rz_buf_read_at(), rz_buf_seek(), and rz_buf_size().
|
static |
Definition at line 615 of file io_zip.c.
References rz_io_zfo_t::b, count, rz_buf_resize(), and rz_buf_tell().
Referenced by rz_io_zip_write().
Definition at line 623 of file io_zip.c.
References fd, rz_io_zfo_t::modified, rz_io_zip_flush_file(), and rz_io_zip_truncate_buf().
|
static |
Definition at line 122 of file io_zip.c.
References rz_io_zfo_t::archivename, rz_io_zfo_t::b, calloc(), rz_io_zfo_t::entry, free(), rz_io_zfo_t::mode, NULL, rz_io_zfo_t::opened, rz_io_zfo_t::perm, rz_io_zfo_t::rw, rz_buf_new_with_bytes(), rz_buf_set_bytes(), rz_io_zip_open_archive(), sb, zip_close(), zip_fclose(), zip_fopen_index(), zip_fread(), zip_stat_index(), and zip_stat_init().
Referenced by rz_io_zip_alloc_zipfileobj().
|
static |
Definition at line 619 of file io_zip.c.
References rz_io_zfo_t::b, and rz_buf_resize().
Referenced by rz_io_zip_resize().
Definition at line 637 of file io_zip.c.
References rz_io_zfo_t::b, count, fd, rz_io_zfo_t::modified, rz_io_t::off, rz_io_zfo_t::perm, RZ_BUF_CUR, rz_buf_seek(), rz_buf_size(), rz_buf_tell(), rz_buf_write_at(), rz_io_zip_flush_file(), rz_io_zip_realloc_buf(), and RZ_PERM_W.
RZ_API RzLibStruct rizin_plugin |
RzIOPlugin rz_io_plugin_zip |
Definition at line 675 of file io_zip.c.
Referenced by find_apk_binary(), rz_io_zip_open(), and rz_io_zip_open_many().
|
static |
Definition at line 33 of file io_zip.c.
Referenced by rz_io_zip_check_uri_many().
|
static |
Definition at line 25 of file io_zip.c.
Referenced by rz_io_zip_check_uri().