libvmdk(3)

NAME
libvmdk.h - Library to access the VMware Virtual Disk (VMDK) format

SYNOPSIS
#include <libvmdk.h>

Support functions
const char *
libvmdk_get_version(void);
int
libvmdk_get_access_flags_read(void);
int
libvmdk_get_codepage(int *codepage, libvmdk_error_t **error);
int
libvmdk_set_codepage(int codepage, libvmdk_error_t **error);
int
libvmdk_check_file_signature(const char *filename, libvmdk_error_t **error);

Available when compiled with wide character string support:
int
libvmdk_check_file_signature_wide(const wchar_t *filename, libvmdk_error_t **error);

Available when compiled with libbfio support:
int
libvmdk_check_file_signature_file_io_handle(libbfio_handle_t *file_io_handle, libvmdk_error_t **error);

Notify functions
void
libvmdk_notify_set_verbose(int verbose);
int
libvmdk_notify_set_stream(FILE *stream, libvmdk_error_t **error);
int
libvmdk_notify_stream_open(const char *filename, libvmdk_error_t **error);
int
libvmdk_notify_stream_close(libvmdk_error_t **error);

Error functions
void
libvmdk_error_free(libvmdk_error_t **error);
int
libvmdk_error_fprint(libvmdk_error_t *error, FILE *stream);
int
libvmdk_error_sprint(libvmdk_error_t *error, char *string, size_t size);
int
libvmdk_error_backtrace_fprint(libvmdk_error_t *error, FILE *stream);
int
libvmdk_error_backtrace_sprint(libvmdk_error_t *error, char *string, size_t size);

Handle functions
int
libvmdk_handle_initialize(libvmdk_handle_t **handle, libvmdk_error_t **error);
int
libvmdk_handle_free(libvmdk_handle_t **handle, libvmdk_error_t **error);
int
libvmdk_handle_signal_abort(libvmdk_handle_t *handle, libvmdk_error_t **error);
int
libvmdk_handle_open(libvmdk_handle_t *handle, const char *filename, int access_flags, libvmdk_error_t **error);
int
libvmdk_handle_open_extent_data_files(libvmdk_handle_t *handle, libvmdk_error_t **error);
int
libvmdk_handle_close(libvmdk_handle_t *handle, libvmdk_error_t **error);
ssize_t
libvmdk_handle_read_buffer(libvmdk_handle_t *handle, void *buffer, size_t buffer_size, libvmdk_error_t **error);
ssize_t
libvmdk_handle_read_buffer_at_offset(libvmdk_handle_t *handle, void *buffer, size_t buffer_size, off64_t offset, libvmdk_error_t **error);
off64_t
libvmdk_handle_seek_offset(libvmdk_handle_t *handle, off64_t offset, int whence, libvmdk_error_t **error);
int
libvmdk_handle_get_offset(libvmdk_handle_t *handle, off64_t *offset, libvmdk_error_t **error);
int
libvmdk_handle_set_maximum_number_of_open_handles(libvmdk_handle_t *handle, int maximum_number_of_open_handles, libvmdk_error_t **error);
int
libvmdk_handle_set_parent_handle(libvmdk_handle_t *handle, libvmdk_handle_t *parent_handle, libvmdk_error_t **error);
int
libvmdk_handle_set_extent_data_files_path(libvmdk_handle_t *handle, const char *path, size_t path_length, libvmdk_error_t **error);

Available when compiled with wide character string support:
int
libvmdk_handle_open_wide(libvmdk_handle_t *handle, const wchar_t *filename, int access_flags, libvmdk_error_t **error);
int
libvmdk_handle_set_extent_data_files_path_wide(libvmdk_handle_t *handle, const wchar_t *path, size_t path_length, libvmdk_error_t **error);

Available when compiled with libbfio support:
int
libvmdk_handle_open_file_io_handle(libvmdk_handle_t *handle, libbfio_handle_t *file_io_handle, int access_flags, libvmdk_error_t **error);
int
libvmdk_handle_open_extent_data_files_file_io_pool(libvmdk_handle_t *handle, libbfio_pool_t *file_io_pool, libvmdk_error_t **error);

Meta data functions
int
libvmdk_handle_get_disk_type(libvmdk_handle_t *handle, int *disk_type, libvmdk_error_t **error);
int
libvmdk_handle_get_media_size(libvmdk_handle_t *handle, size64_t *media_size, libvmdk_error_t **error);
int
libvmdk_handle_get_content_identifier(libvmdk_handle_t *handle, uint32_t *content_identifier, libvmdk_error_t **error);
int
libvmdk_handle_get_parent_content_identifier(libvmdk_handle_t *handle, uint32_t *parent_content_identifier, libvmdk_error_t **error);
int
libvmdk_handle_get_utf8_parent_filename_size(libvmdk_handle_t *handle, size_t *utf8_string_size, libvmdk_error_t **error);
int
libvmdk_handle_get_utf8_parent_filename(libvmdk_handle_t *handle, uint8_t *utf8_string, size_t utf8_string_size, libvmdk_error_t **error);
int
libvmdk_handle_get_utf16_parent_filename_size(libvmdk_handle_t *handle, size_t *utf16_string_size, libvmdk_error_t **error);
int
libvmdk_handle_get_utf16_parent_filename(libvmdk_handle_t *handle, uint16_t *utf16_string, size_t utf16_string_size, libvmdk_error_t **error);
int
libvmdk_handle_get_number_of_extents(libvmdk_handle_t *handle, int *number_of_extents, libvmdk_error_t **error);
int
libvmdk_handle_get_extent_descriptor(libvmdk_handle_t *handle, int extent_index, libvmdk_extent_descriptor_t **extent_descriptor, libvmdk_error_t **error);

Extent descriptor functions
int
libvmdk_extent_descriptor_free(libvmdk_extent_descriptor_t **extent_descriptor, libvmdk_error_t **error);
int
libvmdk_extent_descriptor_get_type(libvmdk_extent_descriptor_t *extent_descriptor, int *type, libvmdk_error_t **error);
int
libvmdk_extent_descriptor_get_range(libvmdk_extent_descriptor_t *extent_descriptor, off64_t *offset, size64_t *size, libvmdk_error_t **error);
int
libvmdk_extent_descriptor_get_utf8_filename_size(libvmdk_extent_descriptor_t *extent_descriptor, size_t *utf8_string_size, libvmdk_error_t **error);
int
libvmdk_extent_descriptor_get_utf8_filename(libvmdk_extent_descriptor_t *extent_descriptor, uint8_t *utf8_string, size_t utf8_string_size, libvmdk_error_t **error);
int
libvmdk_extent_descriptor_get_utf16_filename_size(libvmdk_extent_descriptor_t *extent_descriptor, size_t *utf16_string_size, libvmdk_error_t **error);
int
libvmdk_extent_descriptor_get_utf16_filename(libvmdk_extent_descriptor_t *extent_descriptor, uint16_t *utf16_string, size_t utf16_string_size, libvmdk_error_t **error);

DESCRIPTION
The libvmdk_get_version() function is used to retrieve the library version.

RETURN VALUES
Most of the functions return NULL or -1 on error, dependent on the return type. For the actual return values see "libvmdk.h".

ENVIRONMENT
None

FILES
None

NOTES
libvmdk can be compiled with wide character support (wchar_t).

To compile libvmdk with wide character support use: ./configure --enable-wide-character-type=yes or define: _UNICODE or UNICODE during compilation.

LIBVMDK_WIDE_CHARACTER_TYPE in libvmdk/features.h can be used to determine if libvmdk was compiled with wide character support.

BUGS
Please report bugs of any kind on the project issue tracker: https://github.com/libyal/libvmdk/issues

AUTHOR
These man pages are generated from "libvmdk.h".

COPYRIGHT
Copyright (C) 2009-2024, Joachim Metz <joachim.metz@gmail.com>.

This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

SEE ALSO
the libvmdk.h include file