Skip to content
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

golang: update GetCcReport api #92

Merged
merged 1 commit into from
Oct 16, 2024
Merged

golang: update GetCcReport api #92

merged 1 commit into from
Oct 16, 2024

Conversation

Ruoyu-y
Copy link
Member

@Ruoyu-y Ruoyu-y commented Sep 9, 2024

align golang api with python one

align golang api with python one

Signed-off-by: Ruoyu Ying <[email protected]>
@Ruoyu-y Ruoyu-y requested a review from dongx1x September 9, 2024 06:18
nonceStr := b64.StdEncoding.EncodeToString(nonce)
userDataStr := b64.StdEncoding.EncodeToString(userData)

result, err := client.GetCCReportFromServer(userDataStr, nonceStr)
Copy link
Collaborator

@rihuita rihuita Sep 16, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we modify client.GetCCReportFromServer API also.
I can directly use the GetCCReportFromServer in the ITA client.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In side the GetCCReportFromServer func, can we make the container id to be optional?
If we provide the container id, can we add it at the end of the userData?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we modify client.GetCCReportFromServer API also. I can directly use the GetCCReportFromServer in the ITA client.

The GetCCReportFromServer is currently not an API exposed in CIMA I think. Are you trying to fetch vm level measurement? If that's the case, i think using the vmsdk is a better choice. @dongx1x Please add more comments here.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@rihuita maybe you can use GetCCReport instead of GetCCReportFromServer, since GetCCReportFromServer is designed for transparent communication between client and server. The container id can NOT be optional for container measurement, but there is a parameter to customize the measurement: https://github.com/cc-api/container-integrity-measurement-agent/blob/main/service/cima-server/configs/policy.yaml#L11

@dongx1x dongx1x merged commit 954b05b into cc-api:main Oct 16, 2024
2 of 3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants