hf-cloud-sagemaker-iam-preflight

Pass

Audited by Gen Agent Trust Hub on Sep 17, 2026

Risk Level: SAFECOMMAND_EXECUTION
Full Analysis
  • [COMMAND_EXECUTION]: The skill uses Python's subprocess.run to execute local shell commands via the aws CLI for IAM role discovery and management.
  • Evidence: Both scripts/check_role.py and scripts/create_role.py invoke the aws binary to perform actions like iam list-roles, iam get-role, and iam create-role.
  • Security Review: The scripts use list-based argument passing (e.g., subprocess.run([aws_bin(), *args], ...)), which avoids the use of a shell and mitigates command injection vulnerabilities from user-provided role or bucket names.
  • [PRIVILEGE_ESCALATION]: The skill is designed to create and modify IAM roles/policies, which is a high-privilege operation.
  • Context: This is the primary intended purpose of the skill (pre-flighting SageMaker roles). The skill implements safety checks, such as identifying if the caller is an SSO principal (who typically lack IAM write permissions), and uses a narrowly-scoped "minimum permissions" policy template rather than granting full administrative access.
  • [DATA_EXPOSURE_AND_EXFILTRATION]: The scripts read IAM role configurations and account identity.
  • Security Review: Data retrieved from the AWS CLI is processed locally to rank and validate roles. There are no network operations (e.g., curl, requests) present in the code that would exfiltrate this configuration to an external server.
Audit Metadata
Risk Level
SAFE
Analyzed
Sep 17, 2026, 06:17 AM
Security Audit — agent-trust-hub — hf-cloud-sagemaker-iam-preflight