-
Notifications
You must be signed in to change notification settings - Fork 74
feat: on-chain TCB policy with dcap-qvl two-phase verification #538
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
base: master
Are you sure you want to change the base?
Changes from all commits
bc5c574
6f22de1
879ba19
945b330
27c5d55
2dab2f8
df262e5
3d35952
c006e36
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -30,6 +30,3 @@ jobs: | |
|
|
||
| - name: Cargo fmt check | ||
| run: cargo fmt --check --all | ||
|
|
||
| - name: Run tests | ||
| run: ./run-tests.sh | ||
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| @@ -0,0 +1,73 @@ | ||||||||||||||||||||||||||||||||
| # SPDX-FileCopyrightText: © 2025 Phala Network <dstack@phala.network> | ||||||||||||||||||||||||||||||||
| # | ||||||||||||||||||||||||||||||||
| # SPDX-License-Identifier: Apache-2.0 | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| name: Tests | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| on: | ||||||||||||||||||||||||||||||||
| push: | ||||||||||||||||||||||||||||||||
| branches: [ master, next, dev-* ] | ||||||||||||||||||||||||||||||||
| pull_request: | ||||||||||||||||||||||||||||||||
| branches: [ master, next, dev-* ] | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| env: | ||||||||||||||||||||||||||||||||
| CARGO_TERM_COLOR: always | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| jobs: | ||||||||||||||||||||||||||||||||
| rust-tests: | ||||||||||||||||||||||||||||||||
| name: Rust tests | ||||||||||||||||||||||||||||||||
| runs-on: ubuntu-latest | ||||||||||||||||||||||||||||||||
| steps: | ||||||||||||||||||||||||||||||||
| - uses: actions/checkout@v4 | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| - name: Install Rust | ||||||||||||||||||||||||||||||||
| uses: dtolnay/rust-toolchain@master | ||||||||||||||||||||||||||||||||
| with: | ||||||||||||||||||||||||||||||||
| toolchain: 1.92.0 | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| - name: Run tests | ||||||||||||||||||||||||||||||||
| run: ./run-tests.sh | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| auth-eth-tests: | ||||||||||||||||||||||||||||||||
| name: auth-eth tests | ||||||||||||||||||||||||||||||||
| runs-on: ubuntu-latest | ||||||||||||||||||||||||||||||||
| steps: | ||||||||||||||||||||||||||||||||
| - uses: actions/checkout@v4 | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| - name: Setup Node.js | ||||||||||||||||||||||||||||||||
| uses: actions/setup-node@v4 | ||||||||||||||||||||||||||||||||
| with: | ||||||||||||||||||||||||||||||||
| node-version: '18' | ||||||||||||||||||||||||||||||||
| cache: 'npm' | ||||||||||||||||||||||||||||||||
| cache-dependency-path: kms/auth-eth/package-lock.json | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| - name: Install dependencies | ||||||||||||||||||||||||||||||||
| run: | | ||||||||||||||||||||||||||||||||
| cd kms/auth-eth | ||||||||||||||||||||||||||||||||
| npm ci | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| - name: Run tests | ||||||||||||||||||||||||||||||||
| run: | | ||||||||||||||||||||||||||||||||
| cd kms/auth-eth | ||||||||||||||||||||||||||||||||
| npm test | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| kms-e2e-tests: | ||||||||||||||||||||||||||||||||
|
Comment on lines
+32
to
+54
Check warningCode scanning / CodeQL Workflow does not contain permissions Medium test
Actions job or workflow does not limit the permissions of the GITHUB_TOKEN. Consider setting an explicit permissions block, using the following as a minimal starting point: {contents: read}
Copilot AutofixAI 1 day ago In general, the fix is to add an explicit The best fix without changing functionality is to add a single Concretely:
Suggested changeset
1
.github/workflows/tests.yml
Copilot is powered by AI and may make mistakes. Always verify output.
Refresh and try again.
|
||||||||||||||||||||||||||||||||
| name: KMS E2E tests | ||||||||||||||||||||||||||||||||
| runs-on: ubuntu-latest | ||||||||||||||||||||||||||||||||
| steps: | ||||||||||||||||||||||||||||||||
| - uses: actions/checkout@v4 | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| - name: Install Rust | ||||||||||||||||||||||||||||||||
| uses: dtolnay/rust-toolchain@master | ||||||||||||||||||||||||||||||||
| with: | ||||||||||||||||||||||||||||||||
| toolchain: 1.92.0 | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| - name: Setup Node.js | ||||||||||||||||||||||||||||||||
| uses: actions/setup-node@v4 | ||||||||||||||||||||||||||||||||
| with: | ||||||||||||||||||||||||||||||||
| node-version: '18' | ||||||||||||||||||||||||||||||||
| cache: 'npm' | ||||||||||||||||||||||||||||||||
| cache-dependency-path: kms/auth-eth/package-lock.json | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| - name: Run KMS E2E tests | ||||||||||||||||||||||||||||||||
| run: bash kms/e2e/run-e2e.sh | ||||||||||||||||||||||||||||||||
|
Comment on lines
+55
to
+73
Check warningCode scanning / CodeQL Workflow does not contain permissions Medium test
Actions job or workflow does not limit the permissions of the GITHUB_TOKEN. Consider setting an explicit permissions block, using the following as a minimal starting point: {contents: read}
Copilot AutofixAI 1 day ago To fix the problem, add an explicit Concretely, in
Suggested changeset
1
.github/workflows/tests.yml
Copilot is powered by AI and may make mistakes. Always verify output.
Refresh and try again.
|
||||||||||||||||||||||||||||||||
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Check warning
Code scanning / CodeQL
Workflow does not contain permissions Medium test
Copilot Autofix
AI 1 day ago
Generally, to fix this issue you add an explicit
permissionsblock either at the top level of the workflow (applies to all jobs) or per job, granting only the scopes needed. In this workflow, the jobs only need to read repository contents foractions/checkout; they don’t appear to require any write permissions or access to other privileged scopes.The best fix without changing functionality is to add a root-level
permissionsblock specifyingcontents: read. This ensures GITHUB_TOKEN is restricted to read-only repository contents for all jobs in this workflow. No job-specific overrides or additional scopes are required based on the shown steps. Concretely, in.github/workflows/tests.yml, insert:between the
name: Testsline and theon:section. No imports or additional definitions are needed, as this is purely a YAML configuration change.