pysa-json-models

Parse and validate Pysa NDJSON taint models with sources, sinks, and tito.

7.2k|451|Updated Nov 10, 2017
One-click install
npx skills add https://github.com/facebook/pyre-check --skill pysa-json-models
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: pysa-json-models
Source: https://github.com/facebook/pyre-check/tree/main/.llms/skills/pysa-json-models
Command: npx skills add https://github.com/facebook/pyre-check --skill pysa-json-models

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Pysa JSON model outputs provide structured taint information for static analysis, but they can be hard to read, validate, and reason about without tooling. This skill helps engineers interpret, verify, and debug taint models and issues described in newline-delimited JSON.

Core Features & Use Cases

  • Parse and inspect NDJSON lines representing taint models and issues.
  • Validate field structure (callable, filename, line numbers, sources, sinks, tito) and their relationships.
  • Troubleshoot taint flows by correlating sources, sinks, and taint-in-taint-out data across modules.

Quick Start

Inspect a .models file produced by Pysa and identify the taint sources, sinks, and tito mappings.

Frequently Asked Questions about pysa-json-models

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I parse and read Pysa JSON taint models?

To parse Pysa JSON taint models, you process newline-delimited JSON objects to inspect taint sources, sinks, tito mappings, and sanitizers across Python projects. This validates the field structure and callable relationships within the static analysis output.

What are Pysa taint models and when do I need to debug them?

Pysa taint models are structured newline-delimited JSON outputs from Pyre's static analysis that define sources, sinks, and taint-in-taint-out data. You need to debug them to verify taint flows and validate field structures like callables and line numbers.

How do I validate the structure of newline-delimited JSON model outputs?

Validating newline-delimited JSON model outputs involves checking optional fields and correlating relationships between sources, sinks, tito, and callables. Robust validation ensures the taint definitions and issues described across modules are structurally sound.

Can I troubleshoot taint-in-taint-out flows across different Python modules?

Yes, you can troubleshoot taint-in-taint-out flows across Python modules by correlating the sources and sinks mapped in the NDJSON output. This helps trace how taint data passes through callables and verify the static analysis results.

Why does my Pysa static analysis output have missing fields in the JSON?

Pysa static analysis JSON outputs contain optional fields depending on the specific taint definitions and issues identified. Handling these optional fields robustly is required to accurately interpret sources, sinks, and sanitizers without validation errors.

Does this approach work with Pyre static analysis for Python projects?

Yes, this approach works directly with Pyre static analysis for Python projects by interpreting the .models outputs. It reads the newline-delimited JSON to validate taint definitions and debug issues across the analyzed codebase.