Back to skill

Security audit

a2a-Market-Google-OAuth

Security checks for vulnerabilities and agentic risk

Overview

This is a small OAuth implementation guide whose token references match its stated login/session purpose.

This skill appears appropriate for building a Google OAuth flow, but review any separate runtime code it references before using it in production and ensure refresh tokens are hashed, rotated, and scoped as described.

Vulnerability Patterns
  • Skill Instruction HijackingAlters the agent's session goals or safety constraints when the skill loads
  • Agent Memory PoisoningWrites attacker-controlled rules into memory that affect later sessions
  • Remote Payload Retrieval and ExecutionFetches external code whose behavior can change after review
  • Embedded Malicious CodeShips malicious scripts inside the skill and executes them locally
  • Unauthorized Access and Privilege EscalationObtains permissions beyond the task's legitimate needs
Vulnerability Patterns
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
Findings (1)

Credential Access

High
Category
Privilege Escalation
Content
1. `GET /auth/google/start` builds state + redirect URL.
2. `GET /auth/google/callback` validates state and exchanges code.
3. `upsert_identity(provider, provider_user_id, email)` returns internal principal id.
4. `create_session(principal_id)` returns short-lived access token and refresh token.

## Security Baseline
- Validate `state` and `nonce` against server-side cache.
Confidence
70% confidence
Finding
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.

Static analysis

No suspicious patterns detected.