Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,13 @@

## Unreleased

- n8n, Zapier and Pipedream triggers verify `X-Webhook-Signature` (HMAC-SHA256 of
the raw body) in addition to the marker header. Activation stores the signing
secret privately, rotating it when the webhook already exists. Subscriptions
saved before this change have no secret and reject deliveries; deactivate and
reactivate them. Rotating an endpoint's secret in the Console also requires
reactivation. Make cannot read the raw body and keeps marker authentication.

- Separate webhook receiver secrets from public marker/idempotency metadata.
- Remove the Webhook Creation Key field from all triggers. Each activation uses
its own adapter-generated nonce, so off/on, n8n test listening and Pipedream
Expand Down
4 changes: 3 additions & 1 deletion MAINTAINING.md
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,9 @@ an authenticated per-subscription header supported by the public subscription
contract. A stable unique subscription key determines its private verifier.
Reactivation reuses its owned hook; another callback cannot reuse the key while
that hook exists. Changing a verifier or connection requires explicit lifecycle
and rotation testing. The adapters never emit signing secrets or add a relay.
and rotation testing. The adapters never emit signing secrets or add a relay. n8n, Zapier and Pipedream also verify `X-Webhook-Signature` over the raw body
with the endpoint's signing secret, which `hooks.activate` returns separately and
the adapter stores privately; Make cannot read the raw body and keeps the marker.

All delivery channels can repeat events. Use the event ID in downstream dedupe
storage and a stable business key for effects. Zapier and Pipedream also use that
Expand Down
8 changes: 8 additions & 0 deletions make/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,14 @@ template lookup `templates:read`, and hooks `webhooks:read` plus `webhooks:manag
The universal **Make an API call** module permits only the public allowlist on
the fixed Polymorfa origin; it cannot call arbitrary hosts or change principals.

Make webhooks do not verify `X-Webhook-Signature`. A dedicated webhook's
`communication.json` receives only the parsed `headers` and `body`; no raw request
body is available to IML, and the signature covers the exact raw bytes. Recomputing
it from re-serialized JSON would give false rejections or false acceptance, so the
Make trigger stays on its derived marker header only. Treat that marker as shared
receiver authentication, not as body integrity. The webhook's signing secret is not
requested or stored. Revisit this if Make exposes the raw body.

Writes require a stable business idempotency key and saved ISO start time. Map
native files to base64 and MIME type within the 4 MiB decoded connector limit.
Use string IDs. Deduplicate project-wide events by their stable event ID before
Expand Down
2 changes: 1 addition & 1 deletion make/functions/polymorfaAdvanced.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ class IntegrationError extends Error {
// A write that ended in a server error or is still running has an uncertain outcome, whatever its code.
const uncertain = /unknown|reconciliation/.test(code) || code === 'idempotency_in_progress' || (write && status >= 500);
const wait = retryAfter !== undefined ? ` Wait at least ${retryAfter} seconds; preserve the same key and start time.` : '';
const recovery = code === 'idempotency_completed' ? ' The original write completed. Recover its original result; do not send again with a new key.' : code === 'subscription_receipt_deleted' ? ' The webhook created by this activation was deleted. Activate the trigger again to register a new one.' : uncertain ? ' Reconcile the original write before retrying. Keep its key and start time.' + wait : wait;
const recovery = code === 'signing_secret_unavailable' ? ' Polymorfa did not provide a signing secret. Check that the API key has webhooks:manage, then deactivate and reactivate the trigger.' : code === 'signing_secret_rotation_requires_reconciliation' ? ' The secret rotation outcome is unknown. Deactivate and reactivate the trigger to rotate again.' : code === 'idempotency_completed' ? ' The original write completed. Recover its original result; do not send again with a new key.' : code === 'subscription_receipt_deleted' ? ' The webhook created by this activation was deleted. Activate the trigger again to register a new one.' : uncertain ? ' Reconcile the original write before retrying. Keep its key and start time.' + wait : wait;
super(`Polymorfa ${code}${status ? ` (HTTP ${status})` : ''}${requestId ? `. Request: ${requestId}` : ''}.${recovery}`);
this.name = 'IntegrationError'; this.code = code; this.status = status;
this.requestId = requestId; this.retryAfter = retryAfter;
Expand Down
2 changes: 1 addition & 1 deletion make/functions/polymorfaBody.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ class IntegrationError extends Error {
// A write that ended in a server error or is still running has an uncertain outcome, whatever its code.
const uncertain = /unknown|reconciliation/.test(code) || code === 'idempotency_in_progress' || (write && status >= 500);
const wait = retryAfter !== undefined ? ` Wait at least ${retryAfter} seconds; preserve the same key and start time.` : '';
const recovery = code === 'idempotency_completed' ? ' The original write completed. Recover its original result; do not send again with a new key.' : code === 'subscription_receipt_deleted' ? ' The webhook created by this activation was deleted. Activate the trigger again to register a new one.' : uncertain ? ' Reconcile the original write before retrying. Keep its key and start time.' + wait : wait;
const recovery = code === 'signing_secret_unavailable' ? ' Polymorfa did not provide a signing secret. Check that the API key has webhooks:manage, then deactivate and reactivate the trigger.' : code === 'signing_secret_rotation_requires_reconciliation' ? ' The secret rotation outcome is unknown. Deactivate and reactivate the trigger to rotate again.' : code === 'idempotency_completed' ? ' The original write completed. Recover its original result; do not send again with a new key.' : code === 'subscription_receipt_deleted' ? ' The webhook created by this activation was deleted. Activate the trigger again to register a new one.' : uncertain ? ' Reconcile the original write before retrying. Keep its key and start time.' + wait : wait;
super(`Polymorfa ${code}${status ? ` (HTTP ${status})` : ''}${requestId ? `. Request: ${requestId}` : ''}.${recovery}`);
this.name = 'IntegrationError'; this.code = code; this.status = status;
this.requestId = requestId; this.retryAfter = retryAfter;
Expand Down
2 changes: 1 addition & 1 deletion make/functions/polymorfaEnvelope.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion make/functions/polymorfaHook.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ class IntegrationError extends Error {
// A write that ended in a server error or is still running has an uncertain outcome, whatever its code.
const uncertain = /unknown|reconciliation/.test(code) || code === 'idempotency_in_progress' || (write && status >= 500);
const wait = retryAfter !== undefined ? ` Wait at least ${retryAfter} seconds; preserve the same key and start time.` : '';
const recovery = code === 'idempotency_completed' ? ' The original write completed. Recover its original result; do not send again with a new key.' : code === 'subscription_receipt_deleted' ? ' The webhook created by this activation was deleted. Activate the trigger again to register a new one.' : uncertain ? ' Reconcile the original write before retrying. Keep its key and start time.' + wait : wait;
const recovery = code === 'signing_secret_unavailable' ? ' Polymorfa did not provide a signing secret. Check that the API key has webhooks:manage, then deactivate and reactivate the trigger.' : code === 'signing_secret_rotation_requires_reconciliation' ? ' The secret rotation outcome is unknown. Deactivate and reactivate the trigger to rotate again.' : code === 'idempotency_completed' ? ' The original write completed. Recover its original result; do not send again with a new key.' : code === 'subscription_receipt_deleted' ? ' The webhook created by this activation was deleted. Activate the trigger again to register a new one.' : uncertain ? ' Reconcile the original write before retrying. Keep its key and start time.' + wait : wait;
super(`Polymorfa ${code}${status ? ` (HTTP ${status})` : ''}${requestId ? `. Request: ${requestId}` : ''}.${recovery}`);
this.name = 'IntegrationError'; this.code = code; this.status = status;
this.requestId = requestId; this.retryAfter = retryAfter;
Expand Down
2 changes: 1 addition & 1 deletion make/functions/polymorfaRequest.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ class IntegrationError extends Error {
// A write that ended in a server error or is still running has an uncertain outcome, whatever its code.
const uncertain = /unknown|reconciliation/.test(code) || code === 'idempotency_in_progress' || (write && status >= 500);
const wait = retryAfter !== undefined ? ` Wait at least ${retryAfter} seconds; preserve the same key and start time.` : '';
const recovery = code === 'idempotency_completed' ? ' The original write completed. Recover its original result; do not send again with a new key.' : code === 'subscription_receipt_deleted' ? ' The webhook created by this activation was deleted. Activate the trigger again to register a new one.' : uncertain ? ' Reconcile the original write before retrying. Keep its key and start time.' + wait : wait;
const recovery = code === 'signing_secret_unavailable' ? ' Polymorfa did not provide a signing secret. Check that the API key has webhooks:manage, then deactivate and reactivate the trigger.' : code === 'signing_secret_rotation_requires_reconciliation' ? ' The secret rotation outcome is unknown. Deactivate and reactivate the trigger to rotate again.' : code === 'idempotency_completed' ? ' The original write completed. Recover its original result; do not send again with a new key.' : code === 'subscription_receipt_deleted' ? ' The webhook created by this activation was deleted. Activate the trigger again to register a new one.' : uncertain ? ' Reconcile the original write before retrying. Keep its key and start time.' + wait : wait;
super(`Polymorfa ${code}${status ? ` (HTTP ${status})` : ''}${requestId ? `. Request: ${requestId}` : ''}.${recovery}`);
this.name = 'IntegrationError'; this.code = code; this.status = status;
this.requestId = requestId; this.retryAfter = retryAfter;
Expand Down
2 changes: 1 addition & 1 deletion make/functions/polymorfaResult.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ class IntegrationError extends Error {
// A write that ended in a server error or is still running has an uncertain outcome, whatever its code.
const uncertain = /unknown|reconciliation/.test(code) || code === 'idempotency_in_progress' || (write && status >= 500);
const wait = retryAfter !== undefined ? ` Wait at least ${retryAfter} seconds; preserve the same key and start time.` : '';
const recovery = code === 'idempotency_completed' ? ' The original write completed. Recover its original result; do not send again with a new key.' : code === 'subscription_receipt_deleted' ? ' The webhook created by this activation was deleted. Activate the trigger again to register a new one.' : uncertain ? ' Reconcile the original write before retrying. Keep its key and start time.' + wait : wait;
const recovery = code === 'signing_secret_unavailable' ? ' Polymorfa did not provide a signing secret. Check that the API key has webhooks:manage, then deactivate and reactivate the trigger.' : code === 'signing_secret_rotation_requires_reconciliation' ? ' The secret rotation outcome is unknown. Deactivate and reactivate the trigger to rotate again.' : code === 'idempotency_completed' ? ' The original write completed. Recover its original result; do not send again with a new key.' : code === 'subscription_receipt_deleted' ? ' The webhook created by this activation was deleted. Activate the trigger again to register a new one.' : uncertain ? ' Reconcile the original write before retrying. Keep its key and start time.' + wait : wait;
super(`Polymorfa ${code}${status ? ` (HTTP ${status})` : ''}${requestId ? `. Request: ${requestId}` : ''}.${recovery}`);
this.name = 'IntegrationError'; this.code = code; this.status = status;
this.requestId = requestId; this.retryAfter = retryAfter;
Expand Down
2 changes: 1 addition & 1 deletion make/functions/polymorfaSegment.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ class IntegrationError extends Error {
// A write that ended in a server error or is still running has an uncertain outcome, whatever its code.
const uncertain = /unknown|reconciliation/.test(code) || code === 'idempotency_in_progress' || (write && status >= 500);
const wait = retryAfter !== undefined ? ` Wait at least ${retryAfter} seconds; preserve the same key and start time.` : '';
const recovery = code === 'idempotency_completed' ? ' The original write completed. Recover its original result; do not send again with a new key.' : code === 'subscription_receipt_deleted' ? ' The webhook created by this activation was deleted. Activate the trigger again to register a new one.' : uncertain ? ' Reconcile the original write before retrying. Keep its key and start time.' + wait : wait;
const recovery = code === 'signing_secret_unavailable' ? ' Polymorfa did not provide a signing secret. Check that the API key has webhooks:manage, then deactivate and reactivate the trigger.' : code === 'signing_secret_rotation_requires_reconciliation' ? ' The secret rotation outcome is unknown. Deactivate and reactivate the trigger to rotate again.' : code === 'idempotency_completed' ? ' The original write completed. Recover its original result; do not send again with a new key.' : code === 'subscription_receipt_deleted' ? ' The webhook created by this activation was deleted. Activate the trigger again to register a new one.' : uncertain ? ' Reconcile the original write before retrying. Keep its key and start time.' + wait : wait;
super(`Polymorfa ${code}${status ? ` (HTTP ${status})` : ''}${requestId ? `. Request: ${requestId}` : ''}.${recovery}`);
this.name = 'IntegrationError'; this.code = code; this.status = status;
this.requestId = requestId; this.retryAfter = retryAfter;
Expand Down
14 changes: 14 additions & 0 deletions n8n/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,20 @@ Webhook subscriptions are project-wide. Filtering a workflow after receipt does
not prevent disclosure to n8n. Dedupe by event `id` before downstream effects;
repeated delivery is possible. Delete/disable the owned webhook before revoking its credential.

Each delivery must carry a valid `X-Webhook-Signature` header, an HMAC-SHA256 of
the exact raw request body made with the endpoint's signing secret. The trigger
checks it against the raw bytes before parsing the body, and also checks its
marker header. A missing, duplicate or invalid signature, a missing raw body or
a missing stored secret rejects the delivery. The node's signing secret is
kept in workflow static data and never emitted. Activation returns the secret from the create response, or rotates it
(zero overlap) when the webhook already exists, so activating a trigger replaces
any earlier secret for that webhook.

Triggers saved before signature verification have no stored secret and reject
every delivery. Deactivate and reactivate the workflow to rotate and store a fresh secret.
Rotating the endpoint's signing secret in the Polymorfa Console also invalidates
the stored secret and rejects deliveries until the trigger is reactivated.

n8n executes your workflow under its own hosting and retention settings. Choosing
a Polymorfa EU or Brazil region does not place n8n's processing in that region.
Test with synthetic data and check the platform's logs before release.
Loading
Loading