Skip to content

Commit 24fac29

Browse files
committed
Merge main into PR 1064
2 parents cd87b43 + a946ae3 commit 24fac29

95 files changed

Lines changed: 13649 additions & 1073 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/nightly-security-audit.yml

Lines changed: 37 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -45,36 +45,54 @@ jobs:
4545
echo "---" >> AUDIT_LOG.md
4646
4747
- name: Execute Cargo Deny Checks
48+
id: deny
4849
run: |
4950
echo "## 📦 Dependency License & Advisory Checks (cargo-deny)" >> AUDIT_LOG.md
5051
echo "\`\`\`text" >> AUDIT_LOG.md
51-
cargo deny check licenses bans sources 2>&1 >> AUDIT_LOG.md || echo "cargo-deny failed or flagged warnings" >> AUDIT_LOG.md
52+
if cargo deny check licenses bans sources 2>&1 | tee -a AUDIT_LOG.md; then
53+
echo "deny_exit=0" >> "$GITHUB_OUTPUT"
54+
else
55+
echo "deny_exit=$?" >> "$GITHUB_OUTPUT"
56+
echo "::warning::cargo-deny flagged warnings or errors (see AUDIT_LOG.md)"
57+
fi
5258
echo "\`\`\`" >> AUDIT_LOG.md
5359
echo "---" >> AUDIT_LOG.md
5460
5561
- name: Execute Cargo Audit Sweeps
62+
id: audit
5663
run: |
5764
echo "## 🔍 Vulnerability Advisory Scans (cargo-audit)" >> AUDIT_LOG.md
5865
echo "\`\`\`text" >> AUDIT_LOG.md
59-
cargo audit 2>&1 >> AUDIT_LOG.md || echo "cargo-audit detected critical vulnerability markers" >> AUDIT_LOG.md
66+
set +e
67+
cargo audit 2>&1 | tee -a AUDIT_LOG.md
68+
AUDIT_EXIT=$?
69+
set -e
6070
echo "\`\`\`" >> AUDIT_LOG.md
6171
echo "---" >> AUDIT_LOG.md
72+
if [ "$AUDIT_EXIT" -ne 0 ]; then
73+
echo "::error::cargo-audit found vulnerabilities (exit code $AUDIT_EXIT). See AUDIT_LOG.md for details."
74+
echo "audit_exit=$AUDIT_EXIT" >> "$GITHUB_OUTPUT"
75+
else
76+
echo "audit_exit=0" >> "$GITHUB_OUTPUT"
77+
fi
6278
63-
- name: Mutants Gate — lending
79+
- name: Mutants Gate — propchain-lending
6480
run: |
6581
set -o pipefail
6682
echo "## 🧬 Mutation Gate: lending" >> AUDIT_LOG.md
6783
echo "\`\`\`text" >> AUDIT_LOG.md
68-
cargo mutants -p lending --timeout 120 2>&1 | tee -a AUDIT_LOG.md
84+
cargo mutants -p propchain-lending --timeout 120 2>&1 | tee -a AUDIT_LOG.md
6985
echo "\`\`\`" >> AUDIT_LOG.md
86+
echo "---" >> AUDIT_LOG.md
7087
71-
- name: Mutants Gate — bridge
88+
- name: Mutants Gate — propchain-bridge
7289
run: |
7390
set -o pipefail
7491
echo "## 🧬 Mutation Gate: bridge" >> AUDIT_LOG.md
7592
echo "\`\`\`text" >> AUDIT_LOG.md
76-
cargo mutants -p bridge --timeout 180 2>&1 | tee -a AUDIT_LOG.md
93+
cargo mutants -p propchain-bridge --timeout 180 2>&1 | tee -a AUDIT_LOG.md
7794
echo "\`\`\`" >> AUDIT_LOG.md
95+
echo "---" >> AUDIT_LOG.md
7896
7997
- name: Mutants Gate — oracle
8098
run: |
@@ -83,12 +101,23 @@ jobs:
83101
echo "\`\`\`text" >> AUDIT_LOG.md
84102
cargo mutants -p oracle --timeout 120 2>&1 | tee -a AUDIT_LOG.md
85103
echo "\`\`\`" >> AUDIT_LOG.md
104+
echo "---" >> AUDIT_LOG.md
105+
106+
- name: Evaluate Audit Results
107+
if: always()
108+
run: |
109+
DENY_EXIT="${{ steps.deny.outputs.deny_exit }}"
110+
AUDIT_EXIT="${{ steps.audit.outputs.audit_exit }}"
111+
if [ "$DENY_EXIT" != "0" ] || [ "$AUDIT_EXIT" != "0" ]; then
112+
echo "::error::Security audit found issues. Review AUDIT_LOG.md and fix before proceeding."
113+
exit 1
114+
fi
86115
87116
- name: Commit and Push Security Results to Repo
88117
if: always()
89118
run: |
90119
git config --global user.name "github-actions[bot]"
91120
git config --global user.email "github-actions[bot]@users.noreply.github.com"
92121
git add AUDIT_LOG.md
93-
git diff-index --quiet HEAD || git commit -m "chore(ci): update nightly AUDIT_LOG.md validation tracking profiles [skip ci]"
94-
git push origin HEAD:${{ github.ref }}
122+
git diff-index --quiet HEAD || git commit -m "chore(ci): update nightly AUDIT_LOG.md [skip ci]"
123+
git push origin HEAD:${{ github.ref }}

.github/workflows/smoke-ci.yml

Lines changed: 10 additions & 59 deletions
Original file line numberDiff line numberDiff line change
@@ -1,59 +1,10 @@
1-
name: Smoke CI Gate
2-
3-
on:
4-
push:
5-
branches: [ main, master, develop ]
6-
pull_request:
7-
branches: [ main, master, develop ]
8-
9-
permissions:
10-
contents: read
11-
12-
jobs:
13-
smoke-test:
14-
name: Code Quality & Testing Suite
15-
runs-on: ubuntu-latest
16-
17-
steps:
18-
- name: Checkout Code Repository
19-
uses: actions/checkout@v4
20-
21-
- name: Validate CODEOWNERS coverage for security-critical contracts
22-
shell: bash
23-
run: |
24-
test -f .github/CODEOWNERS
25-
grep -Eq '^/contracts/bridge/\s+@MettaChain/bridge$' .github/CODEOWNERS
26-
grep -Eq '^/contracts/lending/\s+@MettaChain/lending$' .github/CODEOWNERS
27-
grep -Eq '^/contracts/oracle/\s+@MettaChain/oracle$' .github/CODEOWNERS
28-
29-
- name: Install Nightly Rust Toolchain (for fmt)
30-
uses: dtolnay/rust-toolchain@nightly
31-
with:
32-
components: rustfmt
33-
34-
- name: Install Stable Rust Toolchain (for clippy & test)
35-
uses: dtolnay/rust-toolchain@stable
36-
with:
37-
components: clippy
38-
39-
- name: Cache Cargo Build Artifacts
40-
uses: actions/cache@v4
41-
with:
42-
path: |
43-
~/.cargo/bin/
44-
~/.cargo/registry/index/
45-
~/.cargo/registry/cache/
46-
~/.cargo/git/db/
47-
target/
48-
key: ${{ runner.os }}-cargo-smoke-${{ hashFiles('**/Cargo.lock') }}
49-
restore-keys: |
50-
${{ runner.os }}-cargo-smoke-
51-
52-
- name: Check Code Formatting Style (nightly fmt)
53-
run: cargo +nightly fmt --check
54-
55-
- name: Execute Static Analysis Compiler Lints (clippy)
56-
run: cargo clippy --all-targets --all-features -- -D warnings
57-
58-
- name: Run Core Verification Tests (test)
59-
run: cargo test --all-features --workspace
1+
# Smoke CI Gate - TEMPORARILY DISABLED
2+
#
3+
# Disabled at maintainer request. The gate currently fails for EVERY pull
4+
# request regardless of its contents: the pinned dependency set (e.g.
5+
# trie-db 0.28.0) no longer compiles under the stable rustc that CI
6+
# installs fresh on each run (1.98.0), so `cargo clippy --all-targets
7+
# --all-features` aborts before ever reaching project code, and the
8+
# workspace test step hits the same failure.
9+
#
10+
# Re-enable once the dependency/toolchain baseline is refreshed.

AUDIT_LOG.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# 🛡️ Automated Security & Mutation Audit Log
2-
Generated on: Mon Aug 24 03:07:26 UTC 2026
2+
Generated on: Tue Aug 25 03:02:28 UTC 2026
33
---
44
## 📦 Dependency License & Advisory Checks (cargo-deny)
55
```text

Cargo.lock

Lines changed: 24 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ members = [
1212
"contracts/analytics",
1313
"contracts/fees",
1414
"contracts/dex",
15+
"contracts/common",
1516
"contracts/compliance_registry",
1617
"contracts/property-management",
1718
"contracts/fractional",

0 commit comments

Comments
 (0)