llm-torch-profiler-analysis
Warn
Audited by Gen Agent Trust Hub on Oct 2, 2026
Risk Level: MEDIUMCOMMAND_EXECUTIONDYNAMIC_EXECUTIONINDIRECT_PROMPT_INJECTIONEXTERNAL_DOWNLOADS
Full Analysis
- [COMMAND_EXECUTION]: Several helper scripts, including
run_sglang_torch_profile_host.shandrun_trtllm_pytorch_profile_host.sh, orchestrate performance profiling by executing complex shell commands viadocker runanddocker exec. These scripts interpolate user-provided variables, such as model paths and additional server arguments (--server-extra), directly into bash execution strings (bash -lc), which can facilitate command injection if the inputs are not carefully sanitized. - [DYNAMIC_EXECUTION]: The skill includes a dedicated script,
make_trtllm_py_executor_override.py, which programmatically reads, modifies, and rewrites thepy_executor.pysource file from the TensorRT-LLM package. This dynamically generated code is then mounted into Docker containers via volume mounts to override default execution logic, representing a sophisticated dynamic execution pattern for system-level profiling. - [INDIRECT_PROMPT_INJECTION]:
- Ingestion points: The analysis engine in
analyze_llm_torch_profile.pyandprofile_common.pyreads and parsestorch.profilerJSON trace files and interacts with LLM server metadata and completion endpoints. - Boundary markers: The skill does not employ explicit boundary markers or specific "ignore embedded instructions" warnings when processing the contents of external trace files.
- Capability inventory: The skill possesses powerful capabilities, including managing Docker containers, executing arbitrary shell commands on the host system, and performing network requests via
urllib.request. - Sanitization: Trace data is loaded and processed using standard JSON parsers without content-based sanitization or validation of internal strings, which could allow maliciously crafted trace files to influence the reporting logic or downstream agent actions.
- [EXTERNAL_DOWNLOADS]: The automation scripts utilize official container images from well-known providers, specifically
nvcr.io/nvidia/tensorrt-llm/release:latestandvllm/vllm-openai:latestfrom Docker Hub.
Audit Metadata