Intel-SGX TEE Accelerated CRG Integration with Klyshko#98
Intel-SGX TEE Accelerated CRG Integration with Klyshko#98rohithvaidya wants to merge 24 commits intocarbynestack:masterfrom
Conversation
…notice.md Signed-off-by: Sarthak Sharma <sarthak.sharma@datakaveri.org>
Signed-off-by: Sarthak Sharma <sarthaksharma070@gmail.com> Signed-off-by: Sarthak Sharma <sarthak.sharma@datakaveri.org>
Signed-off-by: Sarthak Sharma <sarthak.sharma@datakaveri.org>
Signed-off-by: Sarthak Sharma <sarthak.sharma@datakaveri.org>
Signed-off-by: Sarthak Sharma <sarthak.sharma@datakaveri.org>
Replace raw memcpy with explicit destination size checks to satisfy Codacy and prevent potential buffer overflows in MAC key handling. Signed-off-by: Sarthak Sharma <sarthak.sharma@datakaveri.org>
Signed-off-by: Sarthak Sharma <sarthak.sharma@datakaveri.org>
|
Thank you @rohithvaidya and the entire team at the CDPG / datakaveri for filing this PR, and for the sustained effort that went into it. 💪 🎊 Bringing hardware-backed TEE support to Klyshko's offline phase is a significant milestone for the project. Confidential MPC has long been a topic of interest in the community, and having a concrete, working integration of Intel SGX with Gramine and RA-TLS into the Correlated Randomness Generation pipeline is genuinely exciting. The approach, local attestation within a VCP, mutual remote attestation across VCPs, and secure MAC key exchange via RA-TLS/KII before any tuple generation, is exactly the kind of defense-in-depth design the project needs. The inclusion of a dedicated TEE operator mode that preserves full backward compatibility with non-SGX deployments is also very thoughtful. Before we can continue with the merge process, there are a few items that need to be addressed, two of which are flagged as failing checks on the PR. ❌ Blocking — Please Address Before We Can Proceed1. DCO Sign-off Failing (6 Commits)The DCO check is reporting 6 commits that are missing a
The DCO (Developer Certificate of Origin) requires a To fix, you can rebase interactively and add sign-offs: git rebase -i HEAD~N # where N covers the unsigned commits
# Mark each commit as 'reword', then save
# In each commit message, add:
# Signed-off-by: Rohith Vaidhyanathan <rohith.vaidhyanathan@datakaveri.org>Or, for individual commits: git commit --amend --no-edit --signoff # for the most recent commit
git push --force-with-lease2. Codacy Static Analysis — 100 New IssuesThe Codacy Production check is reporting 100 new issues introduced by this PR. Before we can merge, these need to be reviewed and addressed (or explicitly acknowledged with a justification for those that are false positives or acceptable trade-offs given the SGX/Gramine context). Please review the full findings in the Codacy PR report and work through them systematically. If any findings are deemed false positives or inapplicable (e.g., patterns required by Gramine's C API or SGX calling conventions), please add inline annotations or document the rationale clearly so reviewers can assess. 3. CI Workflow — Build and Test for
|
| package v1alpha1 | ||
|
|
||
| import ( | ||
| corev1 "k8s.io/api/core/v1" |
There was a problem hiding this comment.
corev1 and v1 are two aliases for the exact same package (k8s.io/api/core/v1). The Tolerations field on line 51 uses corev1.Toleration, but since v1 already resolves to the same package, the fix is simply:
Tolerations []v1.Toleration `json:"tolerations,omitempty"`and drop the corev1 import. This duplicate import causes controller-gen v0.6.1 to panic when the tool is compiled with Go 1.17+ (due to changes in go/types internal APIs). While CI currently uses Go 1.16 and doesn't hit the panic, this will break any contributor running a modern Go toolchain locally.
There was a problem hiding this comment.
corev1 k8s import removed from operator as it is redundant
Signed-off-by: Sarthak Sharma <sarthak.sharma@datakaveri.org>
…urity configuration Signed-off-by: rohithvaidya <rohith.vaidhyanathan@datakaveri.org>
Signed-off-by: rohithvaidya <rohith.vaidhyanathan@datakaveri.org>
…ate placeholder files for Gramine Signed-off-by: rohithvaidya <rohith.vaidhyanathan@datakaveri.org>
Signed-off-by: rohithvaidya <rohith.vaidhyanathan@datakaveri.org>
…ockerfile Signed-off-by: rohithvaidya <rohith.vaidhyanathan@datakaveri.org>
Signed-off-by: rohithvaidya <rohith.vaidhyanathan@datakaveri.org>
c0b1463 to
26baf02
Compare
Signed-off-by: rohithvaidya <rohith.vaidhyanathan@datakaveri.org>
Signed-off-by: rohithvaidya <rohith.vaidhyanathan@datakaveri.org>
Signed-off-by: rohithvaidya <rohith.vaidhyanathan@datakaveri.org>
Signed-off-by: rohithvaidya <rohith.vaidhyanathan@datakaveri.org>
Fixes to Static Code Checks and Add Build and Test CI Pipeline
Signed-off-by: rohithvaidya <rohith.vaidhyanathan@datakaveri.org>
fix: Fix CWE-120/CWE-20 issues
Signed-off-by: rohithvaidya <rohith.vaidhyanathan@datakaveri.org>
Operator Import Fix and Static Code Analysis Fixes
Intel SGX–backed secure CRG execution — Runs MP-SPDZ Fake-Offline inside Intel SGX enclaves, providing hardware-backed confidentiality and integrity for the MPC offline phase.
End-to-end attestation workflow — Implements local attestation (same node) and mutual remote attestation across VCPs using RA-TLS with DCAP before any tuple generation.
Secure key exchange via KII — Integrates Klyshko Integration Interface (KII) to securely exchange MAC key shares over attested TLS (protobuf), ensuring correlated randomness generation only after successful enclave verification.
Mixed Mode Klyshko Operator for switching between default Offline Phase and TEE Enabled Offline Phase
Usage and Setup Docs