@pattform/api-kit 2.6.5 → 2.6.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -126,6 +126,22 @@ class FormComponent extends pulumi.ComponentResource {
126
126
  provider: awsProvider,
127
127
  parent: this,
128
128
  });
129
+ // Since October 2025, public NONE function URLs require BOTH
130
+ // lambda:InvokeFunctionUrl and lambda:InvokeFunction in the resource
131
+ // policy — with only the former, every invoke returns 403 Forbidden
132
+ // (AccessDeniedException) despite AuthType NONE. AWS's default policy
133
+ // scopes this with a lambda:InvokedViaFunctionUrl=true condition, which
134
+ // aws.lambda.Permission can't express; omitting it is safe here because
135
+ // anonymous callers can't reach the Invoke API and the handler validates
136
+ // every request (Turnstile + schema) regardless of invocation path.
137
+ const invokePermission = new aws.lambda.Permission(`${baseName}-invoke-public-${env}`, {
138
+ action: "lambda:InvokeFunction",
139
+ function: this.lambda.name,
140
+ principal: "*",
141
+ }, {
142
+ provider: awsProvider,
143
+ parent: this,
144
+ });
129
145
  // Preflight OPTIONS requests are answered by the Function URL itself;
130
146
  // only same-configured origins can read responses from the browser.
131
147
  // deleteBeforeReplace: a function may have only one URL config, so a
@@ -142,7 +158,7 @@ class FormComponent extends pulumi.ComponentResource {
142
158
  }, {
143
159
  provider: awsProvider,
144
160
  parent: this,
145
- dependsOn: [urlPermission],
161
+ dependsOn: [urlPermission, invokePermission],
146
162
  deleteBeforeReplace: true,
147
163
  });
148
164
  this.endpoint = this.functionUrl.functionUrl;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pattform/api-kit",
3
- "version": "2.6.5",
3
+ "version": "2.6.6",
4
4
  "description": "Pulumi infra library for building and deploying an API",
5
5
  "author": "Pattform <contact@pattform.io>",
6
6
  "license": "SEE LICENSE IN LICENSE",