@blamejs/core 0.7.4 → 0.7.19

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.
@@ -183,6 +183,72 @@ var FileUploadError = defineClass("FileUploadError", { alwaysPermane
183
183
  // HTTP responses (403 permission_denied, 404 not_found, 412 precondition_failed,
184
184
  // 416 range_not_satisfiable, 429 quota_exceeded, 451 retention_blocked).
185
185
  var StaticServeError = defineClass("StaticServeError", { withStatusCode: true });
186
+ // GateContractError covers gate-contract violations (operator-supplied
187
+ // gate is malformed / hook threw / runtime exceeded). alwaysPermanent
188
+ // because these are programming-bug-shaped, not transient.
189
+ var GateContractError = defineClass("GateContractError", { alwaysPermanent: true });
190
+ // GuardCsvError covers csv-shape violations on the serialize / sanitize /
191
+ // validate paths. alwaysPermanent — chunk-shape errors / formula-injection
192
+ // attempts / schema drift are all caller-shape errors.
193
+ var GuardCsvError = defineClass("GuardCsvError", { alwaysPermanent: true });
194
+ // GuardAllError covers parity-check failures, exceptFor opt validation, and
195
+ // override opt validation in the b.guardAll registry. alwaysPermanent — every
196
+ // case is a config-time programming bug, not a transient runtime condition.
197
+ var GuardAllError = defineClass("GuardAllError", { alwaysPermanent: true });
198
+ // GuardHtmlError covers html-shape violations on validate / sanitize / escape
199
+ // paths. alwaysPermanent — XSS attempts / dangerous-tag detections / DOM
200
+ // clobbering are all caller-shape errors.
201
+ var GuardHtmlError = defineClass("GuardHtmlError", { alwaysPermanent: true });
202
+ // GuardSvgError covers svg-shape violations: dangerous tags (script /
203
+ // foreignObject / use cross-origin / handler), DOCTYPE entity expansion
204
+ // (billion laughs / XXE), animation-element attributeName targeting href,
205
+ // SVGZ compressed payloads, SSRF-shape href references. alwaysPermanent.
206
+ var GuardSvgError = defineClass("GuardSvgError", { alwaysPermanent: true });
207
+ // GuardFilenameError covers filename-shape violations: path traversal,
208
+ // null-byte truncation, Windows reserved names (CON / PRN / AUX / ...),
209
+ // NTFS alternate data streams, leading/trailing whitespace + trailing dots
210
+ // (Windows strips them silently), unicode bidi/RTLO file-name spoofing,
211
+ // overlong UTF-8 encoding, length caps. alwaysPermanent.
212
+ var GuardFilenameError = defineClass("GuardFilenameError", { alwaysPermanent: true });
213
+ // GuardArchiveError covers archive-shape violations: zip-slip path
214
+ // traversal, symlink + hardlink escape, decompression-ratio bombs,
215
+ // nested-archive depth, file-count + total-size + per-entry-size caps,
216
+ // magic-byte / format-claim mismatch, duplicate entries, encryption-
217
+ // claim mismatch. alwaysPermanent.
218
+ var GuardArchiveError = defineClass("GuardArchiveError", { alwaysPermanent: true });
219
+ // GuardJsonError covers json-shape violations: prototype pollution
220
+ // (__proto__/constructor/prototype), depth + breadth + key-count bombs,
221
+ // duplicate keys, NaN/Infinity/comments (JSON5 extensions), bidi/null
222
+ // in string values, numeric precision loss, total-size cap.
223
+ // alwaysPermanent.
224
+ var GuardJsonError = defineClass("GuardJsonError", { alwaysPermanent: true });
225
+ // GuardYamlError covers yaml-shape violations: deserialization-tag
226
+ // injection (!!python/object / !!java.util.HashMap / custom !Class),
227
+ // anchor recursion (billion laughs), Norway-problem implicit booleans,
228
+ // leading-zero octals, duplicate keys, multi-document streams, depth +
229
+ // node-count + size caps. alwaysPermanent.
230
+ var GuardYamlError = defineClass("GuardYamlError", { alwaysPermanent: true });
231
+ // GuardXmlError covers xml-shape violations: XXE, billion-laughs entity
232
+ // expansion, parameter entities, external DTD subset, XInclude, schema-
233
+ // fetch (xsi:schemaLocation), processing instructions, CDATA, depth +
234
+ // element-count + attribute-count caps. alwaysPermanent.
235
+ var GuardXmlError = defineClass("GuardXmlError", { alwaysPermanent: true });
236
+ // GuardMarkdownError covers markdown-shape violations: raw-HTML smuggling
237
+ // (including the CVE-2026-30838 whitespace-in-tag-name bypass), dangerous
238
+ // link / image / autolink / reference-link URL schemes (javascript: / data:
239
+ // text/html / vbscript: / file: / jar:), entity-encoded scheme bypass,
240
+ // front-matter payloads, ReDoS-prone emphasis / nesting / autolink mass,
241
+ // HTML-comment smuggling, code-fence language injection, depth + link
242
+ // count + image count + line count + size caps. alwaysPermanent.
243
+ var GuardMarkdownError = defineClass("GuardMarkdownError", { alwaysPermanent: true });
244
+ // GuardEmailError covers email-shape violations: SMTP smuggling (bare
245
+ // CR/LF in body, embedded SMTP verbs), CRLF header injection, RFC 5321
246
+ // /5322 local-part / domain / total-length caps, multi-@ violations,
247
+ // IDN homograph spoofing (mixed-script confusable codepoints), display-
248
+ // name vs envelope mismatch, bare IP literal addresses, comment syntax
249
+ // in addresses, bidi/null/control chars in headers + addresses, header-
250
+ // folding smuggling, BOM injection. alwaysPermanent.
251
+ var GuardEmailError = defineClass("GuardEmailError", { alwaysPermanent: true });
186
252
 
187
253
  module.exports = {
188
254
  FrameworkError: FrameworkError,
@@ -212,4 +278,16 @@ module.exports = {
212
278
  LockoutError: LockoutError,
213
279
  FileUploadError: FileUploadError,
214
280
  StaticServeError: StaticServeError,
281
+ GateContractError: GateContractError,
282
+ GuardCsvError: GuardCsvError,
283
+ GuardAllError: GuardAllError,
284
+ GuardHtmlError: GuardHtmlError,
285
+ GuardSvgError: GuardSvgError,
286
+ GuardFilenameError: GuardFilenameError,
287
+ GuardArchiveError: GuardArchiveError,
288
+ GuardJsonError: GuardJsonError,
289
+ GuardYamlError: GuardYamlError,
290
+ GuardXmlError: GuardXmlError,
291
+ GuardMarkdownError: GuardMarkdownError,
292
+ GuardEmailError: GuardEmailError,
215
293
  };