> For the complete documentation index, see [llms.txt](https://docs.medcrypt.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.medcrypt.com/medcrypt-documentation/guardian/api-overview/api-reference/classes/structmedcrypt-guardian-utilities-initializefiles.md).

# medcrypt::guardian::utilities::InitializeFiles

## Overview

This is the storage for initialization files used to [initialize Guardian](/medcrypt-documentation/guardian/api-overview/api-reference/classes/classmedcrypt-guardian-guardian.md#step-2-run-initialize).

**Requirements:**

* All `const char*` inputs should be set to the beginning of the loaded buffer.
* All `size_t` inputs should be set to the size of the data loaded in the buffer.

**Usage example:**

* See [GetInitializeFilesFromPath()](/medcrypt-documentation/guardian/api-overview/api-reference/namespaces/namespacemedcrypt-guardian-utilities.md#function-getinitializefilesfrompath) and [DeleteInitializeFileBuffers()](/medcrypt-documentation/guardian/api-overview/api-reference/namespaces/namespacemedcrypt-guardian-utilities.md#function-deleteinitializefilebuffers) in [FileHelpers.h](https://github.com/MedCrypt/docs/tree/cc6d7e9e4565d200e300a7e4ea03af7b3d489502/Files/FileHelpers_8h.md#file-filehelpers.h) for an example of how to use.

**Include:**

```cpp
#include <InitializeFiles.h>
```

**Syntax:**

```cpp
struct medcrypt::guardian::utilities::InitializeFiles;
```

### Structure members

* [TrustStore](#variable-truststore): Root certificate authority trust store
* [TrustStoreSize](#variable-truststoresize): Device private identity and keys
* [PrivateIdentity](#variable-privateidentity): Device private identity and keys
* [PrivateIdentitySize](#variable-privateidentitysize): Size of the PrivateIdentity data
* [CertifiedProfile](#variable-certifiedprofile): Device certified profile and certificates
* [CertifiedProfileSize](#variable-certifiedprofilesize): Size of the CertifiedProfile data
* [CertifiedCertificateRevocations](#variable-certifiedcertificaterevocations): Certificate revocation list
* [CertifiedCertificateRevocationsSize](#variable-certifiedcertificaterevocationssize): Size of the CertifiedCertificateRevocations data

### Member details

#### TrustStore variable <a href="#variable-truststore" id="variable-truststore"></a>

* **Description:** Root certificate authority TrustStore file buffer for validating certificates.
* **Type:** `const char*`
* **Syntax:**

```cpp
const char * TrustStore;
```

#### TrustStoreSize variable <a href="#variable-truststoresize" id="variable-truststoresize"></a>

* **Description:** Size of the TrustStore file buffer.
* **Type:** `size_t`
* **Syntax:**

```
size_t TrustStoreSize;
```

#### PrivateIdentity variable <a href="#variable-privateidentity" id="variable-privateidentity"></a>

* **Description:** Device private identity containing cryptographic keys.
* **Type:** `const char*`
* **Security:** Must be kept secure and never transmitted.
* **Syntax:**

```cpp
const char * PrivateIdentity;
```

#### PrivateIdentitySize variable <a href="#variable-privateidentitysize" id="variable-privateidentitysize"></a>

* **Description:** Size of the PrivateIdentity file buffer.
* **Type:** `size_t`
* **Syntax:**

```cpp
size_t PrivateIdentitySize;
```

#### CertifiedProfile variable <a href="#variable-certifiedprofile" id="variable-certifiedprofile"></a>

* **Description:** Device certified profile containing certificates and configuration.
* **Type:** `const char*`
* **Syntax:**

```cpp
const char * CertifiedProfile;
```

#### CertifiedProfileSize variable <a href="#variable-certifiedprofilesize" id="variable-certifiedprofilesize"></a>

* **Description:** Size of the CertifiedProfile file buffer.
* **Type:** `size_t`
* **Syntax:**

```
size_t CertifiedProfileSize;
```

#### CertifiedCertificateRevocations variable <a href="#variable-certifiedcertificaterevocations" id="variable-certifiedcertificaterevocations"></a>

* **Description:** File buffer for Certificate Revocation List (CRL).
* **Type:** `const char*`
* **Syntax:**

```cpp
const char * CertifiedCertificateRevocations;
```

#### CertifiedCertificateRevocationsSize variable <a href="#variable-certifiedcertificaterevocationssize" id="variable-certifiedcertificaterevocationssize"></a>

* **Description:** File buffer size for Certificate Revocation List (CRL).
* **Type:** `const char*`
* **Syntax:**

```cpp
size_t CertifiedCertificateRevocationsSize;
```

### Related classes

* [Guardian class](/medcrypt-documentation/guardian/api-overview/api-reference/classes/classmedcrypt-guardian-guardian.md#overview): Uses `InitializeFiles` in [Initialize()](/medcrypt-documentation/guardian/api-overview/api-reference/classes/classmedcrypt-guardian-guardian.md#step-2-run-initialize) function
* [ProvisionFiles struct](/medcrypt-documentation/guardian/api-overview/api-reference/classes/structmedcrypt-guardian-utilities-provisionfiles.md): Similar file structure used for provisioning operations
* [ProvisionOnlineFiles struct](/medcrypt-documentation/guardian/api-overview/api-reference/classes/structmedcrypt-guardian-utilities-provisiononlinefiles.md): File structure used for online provisioning

## Debugging and logging

Guardian does not create log files. Instead, logging is controlled by the application:

* Guardian logs to `stdout` and `stderr`, which appear in the terminal/CLI of the running application during execution. Look for specific error codes or connection failures in the output.
* **Custom logging:** Use `SetLoggingCallback` to redirect log messages to a callback function, stopping terminal output and allowing custom log handling
* **Log control:** Applications can control log level and verbosity.
* **Guardian Cloud UI**: Check the Guardian Cloud interface for additional error details and provisioning status.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.medcrypt.com/medcrypt-documentation/guardian/api-overview/api-reference/classes/structmedcrypt-guardian-utilities-initializefiles.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
