セキュリティポリシー
以下の方針は oxc-project 組織内のすべてのプロジェクトに適用されます。
見落としに気づいた場合は @boshen に連絡してください。
https://www.npmjs.com/~boshen と https://crates.io/users/Boshen が、パッケージとクレートを公開できる唯一のアカウントです。
github.com
- 組織メンバー全員に二要素認証を必須化
- 許可されるのは安全な二要素方式のみ
- GitHub Security Scanning(シークレットスキャンを含む)を有効化
- GitHub Actions: すべてのアクションを完全なコミット SHA にピン留め
- リリースの不変性を有効化 — 公開後にアセットやタグを変更不可
- 署名付きコミットを推奨: https://docs.github.com/en/authentication/managing-commit-signature-verification/signing-commits
- リポジトリ設定では強制しない(外部コントリビュータが貢献できなくなるため)
- 公開用の長寿命トークンは保存しない — 下記の npmjs.com と crates.io の trusted publishing を参照
- セキュリティ更新のため Renovate Bot を利用
- https://docs.zizmor.sh で GitHub Actions の一般的なセキュリティ問題をリント
npmjs.com
- ログインに 2FA を強制
npm publish --provenanceで公開: https://docs.npmjs.com/generating-provenance-statements- trusted publishing を使用: https://docs.npmjs.com/trusted-publishers
- Socket Security を導入
- Renovate Bot に
"minimumReleaseAge": "3 days"を設定し、公開から 3 日以内のパッケージ更新を避ける - pnpm を使用: https://pnpm.io/supply-chain-security
- 自動
postinstallスクリプトはなし
- 自動
crates.io
- trusted publishing で公開: https://crates.io/docs/trusted-publishing
cargo denyで Rust advisory データベース(https://rustsec.org)に照らして依存関係を確認