huawei-cloud-msmodelslim-model-adapt
Warn
Audited by Socket on Nov 18, 2026
1 alert found:
AnomalyAnomalyscripts/step1_generate_test_model.py
LOWAnomalyLOW
scripts/step1_generate_test_model.py
This script builds and saves a reduced-layer, randomly initialized Transformers model from files in a specified model directory. Its notable security risk is enabling trust_remote_code=True during configuration and model loading, which can execute custom code from an untrusted model directory with the script’s privileges. No direct credential theft, exfiltration, or destructive behavior is present in the shown code; severity depends on whether the supplied model files are trusted.
Confidence: 98%Severity: 61%
Audit Metadata