hapijs / hapijs/subtext

subtext underline zlib error

Open
#100 3 comments 0 reactions 0 assignees View on GitHub
support
Dominant language
JavaScript
Stars
24
Forks
27
PR merge metrics
No merged PRs in 30d

Description

#### Support plan

*is this issue currently blocking your project?* no
*is this issue affecting a production system?* yes

#### Context

* *node version*: v16.18.0
* *module version with issue*: "7.0.4
* *last module version without issue*:
* *environment* (e.g. node, browser, native): node
* *used with* (e.g. hapi application, another framework, standalone, ...): hapi application
* *any other relevant information*:

#### What are you trying to achieve or the steps to reproduce?

Standard hapi application currently under security scan fail decompressing invalid data.

#### What was the result you got?

```
node:events:505
throw er; // Unhandled 'error' event
^

Error: Invalid compressed payload
at Gunzip.stream.emit (node_modules/@hapi/subtext/lib/index.js:129:26)
at Gunzip.onerror (node:internal/streams/readable:773:14)
at Gunzip.emit (node:events:527:28)
at Gunzip.stream.emit (node_modules/@hapi/subtext/lib/index.js:132:21)
at emitErrorNT (node:internal/streams/destroy:157:8)
at emitErrorCloseNT (node:internal/streams/destroy:122:3)
at processTicksAndRejections (node:internal/process/task_queues:83:21)
```

Killing the process

#### What result did you expect?

Expected to handle the request and get a 400 http code.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.