# SGX RA Debugging
git clone https://github.com/intel/SGXDataCenterAttestationPrimitives.git
build `SampleCode/QuoteVerificationSample`, normally it’s like (just follow README)
```bash
$source ${sgxsdk_path}/environment
make SGX_DEBUG=1
```
then run app as README tells.
```bash
$ ./app -quote </path/to/quote.dat [default=../QuoteGenerationSample/quote.dat]>
```
The output is like:
And we can see verification returns with a error a003.
```html!
[APP] Info: ECDSA quote path: quote.dat
[APP] Trusted quote verification:
[APP] Info: get target info successfully returned.
[APP] Info: sgx_qv_set_enclave_load_policy successfully returned.
[APP] Info: tee_get_quote_supplemental_data_version_and_size successfully returned.
[APP] Info: latest supplemental data major version: 3, minor version: 2, size: 496
[APP] Info: App: tee_verify_quote successfully returned.
[APP] Error: Ecall: Verify QvE report and identity failed. 0xe050
===========================================
[APP] Untrusted quote verification:
[APP] Info: tee_get_quote_supplemental_data_version_and_size successfully returned.
[APP] Info: latest supplemental data major version: 3, minor version: 2, size: 496
[APP] Info: App: tee_verify_quote successfully returned.
[APP] Warning: App: Verification completed with Non-terminal result: a003
[APP] Info: Supplemental data Major Version: 3
[APP] Info: Supplemental data Minor Version: 2
[APP] Info: Advisory ID: INTEL-SA-00828,INTEL-SA-00837,INTEL-SA-00657,INTEL-SA-00767,INTEL-SA-00615
```
<font color="#f00">[APP] Warning: App: Verification completed with Non-terminal result: a003</font>
which means:
```bash
SGX_QL_QV_RESULT_OUT_OF_DATE_CONFIG_NEEDED = SGX_QL_QV_MK_ERROR(0x0003),
///< The Quote is good but the TCB level of the platform is out of
///< date and additional configuration of the SGX Platform at its
///< current patching level may be needed. The platform needs
///< patching to be at the latest TCB level
```
You can easily generate quote by using gramine's sample repo: https://github.com/gramineproject/gramine.git
Or use this [**sample quote**](https://drive.google.com/file/d/1wCT_hdhpT28TwgbJqyvEHkCq7znuIEFM/view?usp=drive_link).