VirtualBox

Changeset 57577 in vbox for trunk/include/iprt/crypto


Ignore:
Timestamp:
Aug 28, 2015 6:57:36 PM (9 years ago)
Author:
vboxsync
Message:

IPRT,QtGui: Redid the certificate download code in the GUI and reduced the number of unnecessary wrapper methods. Removed RTHttpCertDigest, adding RTHttpFreeResponse and RTHttpFreeResponseText. Also added RTCrPemParseContent.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/include/iprt/crypto/pem.h

    r57572 r57577  
    102102
    103103/**
    104  * Frees sections returned by RTCrPemReadFile.
     104 * Frees sections returned by RTCrPemReadFile and RTCrPemParseContent.
    105105 * @returns IPRT status code.
    106106 * @param   pSectionHead        The first section.
    107107 */
    108108RTDECL(int) RTCrPemFreeSections(PCRTCRPEMSECTION pSectionHead);
     109
     110/**
     111 * Parses the given data and returns a list of binary sections.
     112 *
     113 * If the file isn't an ASCII file or if no markers were found, the entire file
     114 * content is returned as one single section (with pMarker = NULL).
     115 *
     116 * @returns IPRT status code.
     117 * @retval  VINF_EOF if the file is empty. The ppSectionHead value will be NULL.
     118 *
     119 * @param   pvContent       The content bytes to parse.
     120 * @param   cbContent       The number of content bytes.
     121 * @param   fFlags          RTCRPEMREADFILE_F_XXX.
     122 * @param   paMarkers       Array of one or more section markers to look for.
     123 * @param   cMarkers        Number of markers in the array.
     124 * @param   ppSectionHead   Where to return the head of the section list.  Call
     125 *                          RTCrPemFreeSections to free.
     126 * @param   pErrInfo        Where to return extend error info. Optional.
     127 */
     128RTDECL(int) RTCrPemParseContent(void const *pvContent, size_t cbContent, uint32_t fFlags,
     129                                PCRTCRPEMMARKER paMarkers, size_t cMarkers, PCRTCRPEMSECTION *ppSectionHead, PRTERRINFO pErrInfo);
    109130
    110131/**
     
    116137 *
    117138 * @returns IPRT status code.
     139 * @retval  VINF_EOF if the file is empty. The ppSectionHead value will be NULL.
     140 *
    118141 * @param   pszFilename     The path to the file to read.
    119142 * @param   fFlags          RTCRPEMREADFILE_F_XXX.
    120143 * @param   paMarkers       Array of one or more section markers to look for.
    121144 * @param   cMarkers        Number of markers in the array.
    122  * @param   ppSectionHead   Where to return the head of the section list.
     145 * @param   ppSectionHead   Where to return the head of the section list. Call
     146 *                          RTCrPemFreeSections to free.
    123147 * @param   pErrInfo        Where to return extend error info. Optional.
    124148 */
    125149RTDECL(int) RTCrPemReadFile(const char *pszFilename, uint32_t fFlags, PCRTCRPEMMARKER paMarkers, size_t cMarkers,
    126150                            PCRTCRPEMSECTION *ppSectionHead, PRTERRINFO pErrInfo);
    127 /** @name RTCRPEMREADFILE_F_XXX - Flags for RTCrPemReadFile
     151/** @name RTCRPEMREADFILE_F_XXX - Flags for RTCrPemReadFile and
     152 *        RTCrPemParseContent.
    128153 * @{ */
    129154/** Continue on encoding error. */
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette