Skip to content

Free, Open Source, Self-Hosted WhatsApp API Gateway

docs(plugins): state the production pin rule in the install URL schema

Yudhi Armyndharis4b283a8f7a52
diff --git a/src/modules/plugins/dto/plugin.dto.ts b/src/modules/plugins/dto/plugin.dto.ts
index 9d7ce8616..6dc353a18 100644
--- a/src/modules/plugins/dto/plugin.dto.ts
+++ b/src/modules/plugins/dto/plugin.dto.ts
@@ -86,7 +86,10 @@ export class InstallFromUrlDto {
@ApiProperty({
description:
'URL of the plugin .zip to download and install (SSRF-guarded; private-network hosts remain ' +
- 'subject to the guard). https:// is accepted as-is. Plain http:// is only accepted when the URL ' +
+ 'subject to the guard). https:// is accepted without a pin, except that NODE_ENV=production (the ' +
+ 'Docker image default) requires the `#sha256=` pin described below on every URL unless ' +
+ 'PLUGIN_INSTALL_REQUIRE_PIN=false, and PLUGIN_INSTALL_REQUIRE_PIN=true requires it everywhere. ' +
+ 'Plain http:// is only accepted when the URL ' +
'pins the package content — append `#sha256=<64 hex>` (fragment — never sent to the server; query ' +
'params are ignored) — because the package is executable code and must be integrity-protected in ' +
'transit. A pinned digest that does not match the downloaded archive fails the install.',