-
Notifications
You must be signed in to change notification settings - Fork 150
Moved attestation factory back to static method on attestation class … #3682
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Moved attestation factory back to static method on attestation class … #3682
Conversation
…and return a concrete type not a pointer
|
/azp run prepare-pipelines |
|
Azure Pipelines successfully started running 1 pipeline(s). |
|
Tagging @JeffreyRichter and @antkmsft since we were talking about this PR yesterday. |
ahsonkhan
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some minor feedback and questions.
| m_pipeline(attestationClient.m_pipeline), | ||
| m_tokenValidationOptions(attestationClient.m_tokenValidationOptions){}; | ||
| m_tokenValidationOptions(attestationClient.m_tokenValidationOptions), | ||
| m_attestationSigners(attestationClient.m_attestationSigners){}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Breaking change? If so, add CL entry.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All this does is copy a member variable in the copy constructor, is that breaking?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Isn't this adding a new mandatory parameter, that wasn't there before?
...ation/azure-security-attestation/inc/azure/attestation/attestation_administration_client.hpp
Show resolved
Hide resolved
...ation/azure-security-attestation/inc/azure/attestation/attestation_administration_client.hpp
Outdated
Show resolved
Hide resolved
sdk/attestation/azure-security-attestation/inc/azure/attestation/attestation_client.hpp
Outdated
Show resolved
Hide resolved
sdk/attestation/azure-security-attestation/samples/policy/set_sealed_policy.cpp
Show resolved
Hide resolved
...attestation/azure-security-attestation/test/ut/recordings/TpmAttestationTests.AttestTpm.json
Show resolved
Hide resolved
| - `AddIsolatedModeCertificatesOptions` becomes `AddIsolatedModeCertificateOptions` | ||
| - `RemoveIsolatedModeCertificatesOptions` becomes `RemoveIsolatedModeCertificateOptions` | ||
| - Renamed `AttestEnclaveOptions` to `AttestSgxEnclaveOptions` and `AttestOpenEnclaveOptions`. | ||
| - Split out `AttestationClient::Create` into its own factory class `AttestationClientFactory`. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Didn't we also remove RetrieveResponseValidationCollateral in the previous PR or was that always private? I don't see it being called in the CL breaking change list.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Removed in the previous CR.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What do you mean?
It was there in the beta.2 release correct, and the method no longer exists now? That's a breaking change change worth calling out in the changelog, but I don't see it listed in the beta.3 CL.
If it was added and removed during this release, then ignore my comment :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like it was always private. We might want to update the docs on public API that reference the method still, because the end user can't call it:
Line 334 in 0fd0267
| void RetrieveResponseValidationCollateral( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It was public for 1.0.0.beta-1, and was removed for either 1.0.0.beta-2 or 1.0.0.beta-3 (not sure which).
Could you show me the public API documentation for this method? I thought I had searched for all of them and removed them, but it's possible I missed a couple.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There are a couple places (I linked the GitHub search of the codebase above), here's an example:
Lines 98 to 105 in ebe084b
| * @note \b Note: The RetrieveResponseValidationCollateral API \b MUST be called before the | |
| * GetAttestationPolicy API is called to retrieve the information needed to validate the | |
| * result returned by the service. | |
| */ | |
| Response<Models::AttestationToken<std::string>> GetAttestationPolicy( | |
| Models::AttestationType const& attestationType, | |
| GetPolicyOptions const& options = GetPolicyOptions{}, | |
| Azure::Core::Context const& context = Azure::Core::Context{}) const; |
|
/azp run cpp - attestation |
|
Azure Pipelines successfully started running 1 pipeline(s). |
|
/azp run cpp - attestation |
|
Azure Pipelines successfully started running 1 pipeline(s). |
|
/azp run cpp - attestation |
|
Azure Pipelines successfully started running 1 pipeline(s). |
...ation/azure-security-attestation/inc/azure/attestation/attestation_administration_client.hpp
Outdated
Show resolved
Hide resolved
sdk/attestation/azure-security-attestation/inc/azure/attestation/attestation_client.hpp
Outdated
Show resolved
Hide resolved
...ation/azure-security-attestation/inc/azure/attestation/attestation_administration_client.hpp
Outdated
Show resolved
Hide resolved
…ooses the ability to use 'auto'
sdk/attestation/azure-security-attestation/inc/azure/attestation/attestation_client.hpp
Show resolved
Hide resolved
Co-authored-by: Anton Kolesnyk <41349689+antkmsft@users.noreply.github.com>
…om/LarryOsterman/azure-sdk-for-cpp into larryo/attestation_create_by_value
|
/check-enforcer evaluate |
| * @param options The options to customize the client behavior. | ||
| * @return The newly created client. | ||
| */ | ||
| static AttestationAdministrationClient CreateConcrete( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove these if no longer needed.
…and return a concrete type not a pointer
Pull Request Checklist
Please leverage this checklist as a reminder to address commonly occurring feedback when submitting a pull request to make sure your PR can be reviewed quickly:
See the detailed list in the contributing guide.