SageMaker IAM 预检
原名:hf-cloud-sagemaker-iam-preflight
在部署 Hugging Face 模型前检查 SageMaker 所需角色与最小权限。
中文 Skills 技能说明
适合发现缺少权限、信任关系或资源边界问题;只在已授权账户中读取策略,权限修改必须展示差异并由云管理员确认。开源工具可以本地使用;访问 Hugging Face Hub、Spaces、ZeroGPU、AWS 或托管服务时,用户需自行确认中国大陆网络、账户、区域、费用、模型与数据许可证及跨境要求。执行前应读取项目现状和官方文档,输出目标、依据、影响、验证结果与回退方式;没有真实证据时明确说明未知,不编造配置、数据或成功状态。 代码、日志、令牌、连接串、模型、数据集和企业资料按敏感内容处理,只读取任务所需范围,上传或外发前完成授权、脱敏和最小化。 安全能力仅用于已授权的防御性审计和加固,不执行攻击利用、凭据获取、未授权扫描或安全控制绕过。
上游能力依据
上游原始适用说明:Ensure a usable SageMaker execution role exists before deploying or training. Use this skill whenever about to create a SageMaker endpoint, model, training job, or any resource that requires an execution role. Use it especially when the user has not provided a role ARN explicitly, when scripts are about to call iam:CreateRole, or when an AccessDenied error mentions an IAM action. Never blindly call iam:CreateRole — always check for existing roles first. This skill prevents the most common SageMaker deployment failure: trying to create IAM resources from an SSO principal that has no IAM write permissions.
上游 SKILL.md 主要章节(保留原文标题):
- Running the helpers (cross-platform)
- Order of operations
- Step 1 — Did the user provide a role?
- Step 2 — Discover existing roles
- Step 3 — Create, only if discovery found nothing
- What "validated" means
- Minimum permissions
- Native AWS CLI equivalent (fallback)
使用边界
先确认授权范围、资产边界和证据来源。输出用于防御性检查与人工决策,不自动执行攻击、绕过或破坏性操作。
作者、翻译与许可证
- 原作者
- Hugging Face 与 huggingface/skills contributors
- 中文翻译
- CEOFans翻译
- 许可证
- Apache-2.0
- 上游来源
- https://github.com/huggingface/skills/tree/cead19e10754e773bad24fecef83cb64be24094e/skills/hf-cloud-sagemaker-iam-preflight
适用范围
平台:linux、macos、windows;标签:安全与合规、SageMaker IAM 预检
安全提示
基础静态扫描不等于绝对安全。技能可能调用命令、浏览器、云服务或本地文件,请在最小权限环境中使用,高风险操作必须人工确认。
如发现侵权、许可证或安全问题,可在本页前台提交投诉,管理员复核后可立即下架。