manifest.h revision 5eda82e218d35ae0691febd531e1bfc0324cc4a6
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/** @file
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * IPRT - Manifest file handling.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/*
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * Copyright (C) 2009 Oracle Corporation
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * This file is part of VirtualBox Open Source Edition (OSE), as
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * available from http://www.virtualbox.org. This file is free software;
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * you can redistribute it and/or modify it under the terms of the GNU
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * General Public License (GPL) as published by the Free Software
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * Foundation, in version 2 as it comes in the "COPYING" file of the
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * The contents of this file may alternatively be used under the terms
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * of the Common Development and Distribution License Version 1.0
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * (CDDL) only, as it comes in the "COPYING.CDDL" file of the
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * VirtualBox OSE distribution, in which case the provisions of the
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * CDDL are applicable instead of those of the GPL.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * You may elect to license modified versions of this file under the
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * terms and conditions of either the GPL or the CDDL or both.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync#ifndef ___iprt_manifest_h
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync#define ___iprt_manifest_h
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync#include <iprt/cdefs.h>
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync#include <iprt/types.h>
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsyncRT_C_DECLS_BEGIN
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/** @defgroup grp_rt_manifest RTManifest - Manifest file creation and checking
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @ingroup grp_rt
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @{
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/** @name Manifest attribute types.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * The types can be ORed together to form a set.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @{ */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/** For use with other attributes. Representation unknown. */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync#define RTMANIFEST_ATTR_UNKNOWN 0
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/** The size of the content. Represented as a decimal number. */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync#define RTMANIFEST_ATTR_SIZE RT_BIT_32(0)
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/** The MD5 of the content. Represented as a hex string. */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync#define RTMANIFEST_ATTR_MD5 RT_BIT_32(1)
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/** The SHA-1 of the content. Represented as a hex string. */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync#define RTMANIFEST_ATTR_SHA1 RT_BIT_32(2)
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/** The SHA-256 of the content. Represented as a hex string. */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync#define RTMANIFEST_ATTR_SHA256 RT_BIT_32(3)
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/** The SHA-512 of the content. Represented as a hex string. */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync#define RTMANIFEST_ATTR_SHA512 RT_BIT_32(4)
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/** The end of the valid values. */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync#define RTMANIFEST_ATTR_END RT_BIT_32(5)
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/** @} */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/**
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * Creates an empty manifest.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @returns IPRT status code.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param fFlags Flags, MBZ.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param phManifest Where to return the handle to the manifest.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsyncRTDECL(int) RTManifestCreate(uint32_t fFlags, PRTMANIFEST phManifest);
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/**
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * Retains a reference to the manifest handle.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @returns The new reference count, UINT32_MAX if the handle is invalid.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param hManifest The handle to retain.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsyncRTDECL(uint32_t) RTManifestRetain(RTMANIFEST hManifest);
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/**
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * Releases a reference to the manifest handle.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @returns The new reference count, 0 if free. UINT32_MAX is returned if the
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * handle is invalid.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param hManifest The handle to release.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * NIL is quietly ignored (returns 0).
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsyncRTDECL(uint32_t) RTManifestRelease(RTMANIFEST hManifest);
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/**
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * Creates a duplicate of the specified manifest.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @returns IPRT status code
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param hManifestSrc The manifest to clone.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param phManifestDst Where to store the handle to the duplicate.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsyncRTDECL(int) RTManifestDup(RTMANIFEST hManifestSrc, PRTMANIFEST phManifestDst);
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/**
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * Compares two manifests for equality.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @returns IPRT status code.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @retval VINF_SUCCESS if equal.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @retval VERR_NOT_EQUAL if not equal.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param hManifest1 The first manifest.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param hManifest2 The second manifest.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param papszIgnoreEntries Entries to ignore. Ends with a NULL entry.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param papszIgnoreAttrs Attributes to ignore. Ends with a NULL entry.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param fFlags A combination of RTMANIFEST_EQUALS_XXX values.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param pszError Where to store the name of the mismatching
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * entry, or as much of the name as there is room
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * for. This is always set. Optional.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param cbError The size of the buffer pointed to by @a
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * pszError.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsyncRTDECL(int) RTManifestEqualsEx(RTMANIFEST hManifest1, RTMANIFEST hManifest2, const char * const *papszIgnoreEntries,
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync const char * const *papszIgnoreAttr, uint32_t fFlags, char *pszError, size_t cbError);
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/** @defgroup RTMANIFEST_EQUALS_XXX RTManifestEqualsEx flags
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @{ */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/** Ignore missing attributes if there is one or more to compare. */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync#define RTMANIFEST_EQUALS_IGN_MISSING_ATTRS RT_BIT_32(0)
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/** Ignore attributes missing in the 1st manifest.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @todo implement this */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync#define RTMANIFEST_EQUALS_IGN_MISSING_ATTRS_1ST RT_BIT_32(1)
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/** Mask of valid flags. */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync#define RTMANIFEST_EQUALS_VALID_MASK UINT32_C(0x00000003)
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/** @} */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/**
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * Compares two manifests for equality.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @returns IPRT status code.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @retval VINF_SUCCESS if equal.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @retval VERR_NOT_EQUAL if not equal.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param hManifest1 The first manifest.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param hManifest2 The second manifest.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsyncRTDECL(int) RTManifestEquals(RTMANIFEST hManifest1, RTMANIFEST hManifest2);
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/**
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * Sets a manifest attribute.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @returns IPRT status code.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param hManifest The manifest handle.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param pszAttr The attribute name. If this already exists,
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * its value will be replaced.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param pszValue The value string.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param fType The attribute type, pass
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * RTMANIFEST_ATTR_UNKNOWN if not known.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsyncRTDECL(int) RTManifestSetAttr(RTMANIFEST hManifest, const char *pszAttr, const char *pszValue, uint32_t fType);
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/**
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * Unsets (removes) a manifest attribute if it exists.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @returns IPRT status code.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @retval VWRN_NOT_FOUND if not found.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param hManifest The manifest handle.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param pszAttr The attribute name.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsyncRTDECL(int) RTManifestUnsetAttr(RTMANIFEST hManifest, const char *pszAttr);
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/**
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * Sets an attribute of a manifest entry.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @returns IPRT status code.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param hManifest The manifest handle.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param pszEntry The entry name. This will automatically be
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * added if there was no previous call to
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * RTManifestEntryAdd for this name. See
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * RTManifestEntryAdd for the entry name rules.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param pszAttr The attribute name. If this already exists,
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * its value will be replaced.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param pszValue The value string.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param fType The attribute type, pass
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * RTMANIFEST_ATTR_UNKNOWN if not known.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsyncRTDECL(int) RTManifestEntrySetAttr(RTMANIFEST hManifest, const char *pszEntry, const char *pszAttr,
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync const char *pszValue, uint32_t fType);
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/**
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * Unsets (removes) an attribute of a manifest entry if they both exist.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @returns IPRT status code.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @retval VWRN_NOT_FOUND if not found.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param hManifest The manifest handle.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param pszEntry The entry name.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param pszAttr The attribute name.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsyncRTDECL(int) RTManifestEntryUnsetAttr(RTMANIFEST hManifest, const char *pszEntry, const char *pszAttr);
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/**
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * Adds a new entry to a manifest.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * The entry name rules:
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * - The entry name can contain any character defined by unicode, except
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * control characters, ':', '(' and ')'. The exceptions are mainly there
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * because of uncertainty around how various formats handles these.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * - It is considered case sensitive.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * - Forward (unix) and backward (dos) slashes are considered path
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * separators and converted to forward slashes.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @returns IPRT status code.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @retval VWRN_ALREADY_EXISTS if the entry already exists.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param hManifest The manifest handle.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param pszEntry The entry name (UTF-8).
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @remarks Some manifest formats will not be able to store an entry without
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * any attributes. So, this is just here in case it comes in handy
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * when dealing with formats which can.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsyncRTDECL(int) RTManifestEntryAdd(RTMANIFEST hManifest, const char *pszEntry);
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/**
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * Removes an entry.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @returns IPRT status code.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param hManifest The manifest handle.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param pszEntry The entry name.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsyncRTDECL(int) RTManifestEntryRemove(RTMANIFEST hManifest, const char *pszEntry);
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/**
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * Add an entry for an I/O stream using a passthru stream.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * The passthru I/O stream will hash all the data read from or written to the
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * stream and automatically add an entry to the manifest with the desired
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * attributes when it is released. Alternatively one can call
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * RTManifestPtIosAddEntryNow() to have more control over exactly when this
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * action is performed and which status it yields.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @returns IPRT status code.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param hManifest The manifest to add the entry to.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param hVfsIos The I/O stream to pass thru to/from.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param pszEntry The entry name.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param fAttrs The attributes to create for this stream.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param fReadOrWrite Whether it's a read or write I/O stream.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param phVfsIosPassthru Where to return the new handle.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsyncRTDECL(int) RTManifestEntryAddPassthruIoStream(RTMANIFEST hManifest, RTVFSIOSTREAM hVfsIos, const char *pszEntry,
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync uint32_t fAttrs, bool fReadOrWrite, PRTVFSIOSTREAM phVfsIosPassthru);
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/**
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * Adds the entry to the manifest right now.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @returns IPRT status code.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param hVfsPtIos The manifest passthru I/O stream returned by
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * RTManifestEntryAddPassthruIoStream().
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsyncRTDECL(int) RTManifestPtIosAddEntryNow(RTVFSIOSTREAM hVfsPtIos);
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/**
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * Adds an entry for a file with the specified set of attributes.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @returns IPRT status code.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param hManifest The manifest handle.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param hVfsIos The I/O stream handle of the entry. This will
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * be processed to its end on successful return.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * (Must be positioned at the start to get
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * the expected results.)
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param pszEntry The entry name.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param fAttrs The attributes to create for this stream. See
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * RTMANIFEST_ATTR_XXX.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsyncRTDECL(int) RTManifestEntryAddIoStream(RTMANIFEST hManifest, RTVFSIOSTREAM hVfsIos, const char *pszEntry, uint32_t fAttrs);
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/**
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * Checks if there is a manifest entry by the given name.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @returns true if there is, false if not or if the handle is invalid.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param hManifest The manifest handle.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param pszEntry The entry name.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsyncRTDECL(bool) RTManifestEntryExists(RTMANIFEST hManifest, const char *pszEntry);
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/**
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * Reads in a "standard" manifest.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * This reads the format used by OVF, the distinfo in FreeBSD ports, and
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * others.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @returns IPRT status code.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param hManifest The handle to the manifest where to add the
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * manifest that's read in.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param hVfsIos The I/O stream to read the manifest from.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsyncRTDECL(int) RTManifestReadStandard(RTMANIFEST hManifest, RTVFSIOSTREAM hVfsIos);
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/**
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * Reads in a "standard" manifest.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * This reads the format used by OVF, the distinfo in FreeBSD ports, and
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * others.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @returns IPRT status code.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param hManifest The handle to the manifest where to add the
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * manifest that's read in.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param hVfsIos The I/O stream to read the manifest from.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param pszErr Where to return extended error info on failure.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * Optional.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param cbErr The size of the buffer @a pszErr points to.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsyncRTDECL(int) RTManifestReadStandardEx(RTMANIFEST hManifest, RTVFSIOSTREAM hVfsIos, char *pszErr, size_t cbErr);
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/**
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * Reads in a "standard" manifest from the specified file.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * This reads the format used by OVF, the distinfo in FreeBSD ports, and
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * others.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @returns IPRT status code.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param hManifest The handle to the manifest where to add the
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * manifest that's read in.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param pszFilename The name of the file to read in.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsyncRTDECL(int) RTManifestReadStandardFromFile(RTMANIFEST hManifest, const char *pszFilename);
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/**
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * Writes a "standard" manifest.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * This writes the format used by OVF, the distinfo in FreeBSD ports, and
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * others.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @returns IPRT status code.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param hManifest The handle to the manifest to write.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param hVfsIos The I/O stream to read the manifest from.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsyncRTDECL(int) RTManifestWriteStandard(RTMANIFEST hManifest, RTVFSIOSTREAM hVfsIos);
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/**
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * Writes a "standard" manifest to the specified file.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @returns IPRT status code.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param hManifest The handle to the manifest to write.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param pszFilename The name of the file.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsyncRTDECL(int) RTManifestWriteStandardToFile(RTMANIFEST hManifest, const char *pszFilename);
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/**
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * Input structure for RTManifestVerify() which contains the filename & the
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * SHA1 digest.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsynctypedef struct RTMANIFESTTEST
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync{
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync /** The filename. */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync const char *pszTestFile;
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync /** The SHA1 digest of the file. */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync const char *pszTestDigest;
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync} RTMANIFESTTEST;
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/** Pointer to the input structure. */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsynctypedef RTMANIFESTTEST* PRTMANIFESTTEST;
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/**
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * Verify the given SHA1 digests against the entries in the manifest file.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * Please note that not only the various digest have to match, but the
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * filenames as well. If there are more or even less files listed in the
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * manifest file than provided by paTests, VERR_MANIFEST_FILE_MISMATCH will be
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * returned.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @returns iprt status code.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param pszManifestFile Filename of the manifest file to verify.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param paTests Array of files & SHA1 sums.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param cTests Number of entries in paTests.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param piFailed A index to paTests in the
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * VERR_MANIFEST_DIGEST_MISMATCH error case
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * (optional).
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsyncRTR3DECL(int) RTManifestVerify(const char *pszManifestFile, PRTMANIFESTTEST paTests, size_t cTests, size_t *piFailed);
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/**
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * This is analogous to function RTManifestVerify(), but calculates the SHA1
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * sums of the given files itself.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @returns iprt status code.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param pszManifestFile Filename of the manifest file to verify.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param papszFiles Array of files to check SHA1 sums.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param cFiles Number of entries in papszFiles.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param piFailed A index to papszFiles in the
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * VERR_MANIFEST_DIGEST_MISMATCH error case
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * (optional).
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param pfnProgressCallback optional callback for the progress indication
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param pvUser user defined pointer for the callback
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsyncRTR3DECL(int) RTManifestVerifyFiles(const char *pszManifestFile, const char * const *papszFiles, size_t cFiles, size_t *piFailed,
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync PFNRTPROGRESS pfnProgressCallback, void *pvUser);
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/**
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * Creates a manifest file for a set of files. The manifest file contains SHA1
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * sums of every provided file and could be used to verify the data integrity
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * of them.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @returns iprt status code.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param pszManifestFile Filename of the manifest file to create.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param papszFiles Array of files to create SHA1 sums for.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param cFiles Number of entries in papszFiles.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param pfnProgressCallback optional callback for the progress indication
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param pvUser user defined pointer for the callback
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsyncRTR3DECL(int) RTManifestWriteFiles(const char *pszManifestFile, const char * const *papszFiles, size_t cFiles,
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync PFNRTPROGRESS pfnProgressCallback, void *pvUser);
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/**
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * Verify the given SHA1 digests against the entries in the manifest file in
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * memory.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @returns iprt status code.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param pvBuf Pointer to memory buffer of the manifest file.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param cbSize Size of the memory buffer.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param paTests Array of file names and digests.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param cTest Number of entries in paTests.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param piFailed A index to paTests in the
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * VERR_MANIFEST_DIGEST_MISMATCH error case
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * (optional).
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsyncRTR3DECL(int) RTManifestVerifyFilesBuf(void *pvBuf, size_t cbSize, PRTMANIFESTTEST paTests, size_t cTests, size_t *piFailed);
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/**
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * Creates a manifest file in memory for a set of files. The manifest file
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * contains SHA1 sums of every provided file and could be used to verify the
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * data integrity of them.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @returns iprt status code.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync *
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param ppvBuf Pointer to resulting memory buffer.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param pcbSize Pointer for the size of the memory buffer.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param paFiles Array of file names and digests.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync * @param cFiles Number of entries in paFiles.
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsyncRTR3DECL(int) RTManifestWriteFilesBuf(void **ppvBuf, size_t *pcbSize, PRTMANIFESTTEST paFiles, size_t cFiles);
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync/** @} */
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsyncRT_C_DECLS_END
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync#endif
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync
41d680dd6eb0287afc200adc5b0d61b07a32b72dvboxsync