@postalsys/email-text-tools 2.4.18 → 2.4.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.
- package/.github/VULNERABILITY_REPORT.yml +75 -0
- package/.ncurc.js +5 -1
- package/.release-please-manifest.json +1 -1
- package/CHANGELOG.md +7 -0
- package/SECURITY.md +125 -50
- package/package.json +4 -4
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
name: '@postalsys/email-text-tools security vulnerability report'
|
|
2
|
+
description: 'Report an exploitable security vulnerability in @postalsys/email-text-tools'
|
|
3
|
+
|
|
4
|
+
body:
|
|
5
|
+
- type: markdown
|
|
6
|
+
attributes:
|
|
7
|
+
value: |
|
|
8
|
+
Before reporting, read our
|
|
9
|
+
[Security Policy](https://github.com/postalsys/email-text-tools/security/policy).
|
|
10
|
+
|
|
11
|
+
Reports must demonstrate a credible security impact.
|
|
12
|
+
Technically valid bugs without a realistic attack
|
|
13
|
+
scenario belong in the regular issue tracker.
|
|
14
|
+
|
|
15
|
+
- type: textarea
|
|
16
|
+
id: summary
|
|
17
|
+
attributes:
|
|
18
|
+
label: Vulnerability summary
|
|
19
|
+
description: Describe the vulnerability and affected versions.
|
|
20
|
+
validations:
|
|
21
|
+
required: true
|
|
22
|
+
|
|
23
|
+
- type: textarea
|
|
24
|
+
id: attacker
|
|
25
|
+
attributes:
|
|
26
|
+
label: Attacker capabilities
|
|
27
|
+
description: |
|
|
28
|
+
What can an attacker control without already having
|
|
29
|
+
privileged access to the application or its configuration?
|
|
30
|
+
validations:
|
|
31
|
+
required: true
|
|
32
|
+
min_length: 100
|
|
33
|
+
|
|
34
|
+
- type: textarea
|
|
35
|
+
id: exploit
|
|
36
|
+
attributes:
|
|
37
|
+
label: Realistic exploitation scenario
|
|
38
|
+
description: |
|
|
39
|
+
Describe how this can be exploited in a real application.
|
|
40
|
+
Explain the prerequisites and security boundary crossed.
|
|
41
|
+
validations:
|
|
42
|
+
required: true
|
|
43
|
+
min_length: 150
|
|
44
|
+
|
|
45
|
+
- type: textarea
|
|
46
|
+
id: poc
|
|
47
|
+
attributes:
|
|
48
|
+
label: Proof of concept
|
|
49
|
+
description: Provide reproducible steps or working code.
|
|
50
|
+
validations:
|
|
51
|
+
required: true
|
|
52
|
+
|
|
53
|
+
- type: textarea
|
|
54
|
+
id: impact
|
|
55
|
+
attributes:
|
|
56
|
+
label: Security impact
|
|
57
|
+
description: |
|
|
58
|
+
What can the attacker achieve? Who is affected?
|
|
59
|
+
Explain why this is a security vulnerability rather
|
|
60
|
+
than an ordinary bug.
|
|
61
|
+
validations:
|
|
62
|
+
required: true
|
|
63
|
+
min_length: 100
|
|
64
|
+
|
|
65
|
+
- type: checkboxes
|
|
66
|
+
id: confirmation
|
|
67
|
+
attributes:
|
|
68
|
+
label: Reporting requirements
|
|
69
|
+
options:
|
|
70
|
+
- label: I have read the Security Policy.
|
|
71
|
+
required: true
|
|
72
|
+
- label: I have verified the finding against a supported version.
|
|
73
|
+
required: true
|
|
74
|
+
- label: I have described a credible attacker-controlled scenario.
|
|
75
|
+
required: true
|
package/.ncurc.js
CHANGED
|
@@ -13,6 +13,10 @@ module.exports = {
|
|
|
13
13
|
// 6.0.0 changed the CommonJS export shape (named bindings instead of the constructor) and,
|
|
14
14
|
// more importantly, stopped linkifying bare domains such as 'example.com' or 'www.example.org'
|
|
15
15
|
// by default, which silently breaks autolinking in plain text emails. Stay on 5.x.
|
|
16
|
-
'linkify-it'
|
|
16
|
+
'linkify-it',
|
|
17
|
+
// 2.0.0 is ESM-only (exports only src/he.mjs) and requires Node >=22, so require('he') throws
|
|
18
|
+
// and pkg cannot bundle it. 1.2.0 is the last CommonJS release; EmailEngine and mailparser
|
|
19
|
+
// hold it there too, and a different copy here would be a second he in their trees
|
|
20
|
+
'he'
|
|
17
21
|
]
|
|
18
22
|
};
|
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,12 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [2.4.19](https://github.com/postalsys/email-text-tools/compare/v2.4.18...v2.4.19) (2026-10-14)
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
### Bug Fixes
|
|
7
|
+
|
|
8
|
+
* **deps:** update dompurify to 3.4.17 and hold he on 1.x ([7a900b0](https://github.com/postalsys/email-text-tools/commit/7a900b03f4fbf4001bb21dffa62c659a89917e74))
|
|
9
|
+
|
|
3
10
|
## [2.4.18](https://github.com/postalsys/email-text-tools/compare/v2.4.17...v2.4.18) (2026-09-28)
|
|
4
11
|
|
|
5
12
|
|
package/SECURITY.md
CHANGED
|
@@ -1,81 +1,156 @@
|
|
|
1
1
|
# Security Policy
|
|
2
2
|
|
|
3
|
-
`@postalsys/email-text-tools` converts and sanitizes email content for display
|
|
4
|
-
|
|
5
|
-
arbitrary (
|
|
6
|
-
|
|
7
|
-
|
|
3
|
+
`@postalsys/email-text-tools` converts and sanitizes email content for display:
|
|
4
|
+
it turns plain text into HTML, HTML into plain text, and sanitizes and
|
|
5
|
+
CSS-inlines arbitrary (often untrusted) email HTML into markup that is safe to
|
|
6
|
+
render. We welcome responsible reports of vulnerabilities that present a
|
|
7
|
+
credible security risk to users. Please distinguish security vulnerabilities
|
|
8
|
+
from ordinary bugs, unusual edge cases, and hardening suggestions.
|
|
8
9
|
|
|
9
10
|
## Supported Versions
|
|
10
11
|
|
|
11
|
-
Security fixes are released only against the latest version. We do not
|
|
12
|
-
patches to older
|
|
13
|
-
supported way to receive security updates.
|
|
12
|
+
Security fixes are released only against the latest major version. We do not
|
|
13
|
+
backport patches to older majors, so upgrading to the current release line is
|
|
14
|
+
the supported way to receive security updates.
|
|
14
15
|
|
|
15
16
|
| Version | Supported |
|
|
16
17
|
| ------- | ------------------ |
|
|
17
18
|
| 2.x | :white_check_mark: |
|
|
18
19
|
| < 2.0 | :x: |
|
|
19
20
|
|
|
20
|
-
If you are on an older
|
|
21
|
+
If you are on an older major, please upgrade. See the release notes at
|
|
21
22
|
<https://github.com/postalsys/email-text-tools/releases> before updating.
|
|
22
23
|
|
|
23
|
-
##
|
|
24
|
+
## What Qualifies as a Security Vulnerability
|
|
24
25
|
|
|
25
|
-
|
|
26
|
-
|
|
26
|
+
A security report should identify a realistic way for an attacker to cross a
|
|
27
|
+
security boundary in a supported version of `@postalsys/email-text-tools`.
|
|
28
|
+
Unexpected behavior, a failing test, or a technically correct proof of concept
|
|
29
|
+
is not sufficient on its own to establish security impact.
|
|
27
30
|
|
|
28
|
-
|
|
31
|
+
In particular, explain:
|
|
29
32
|
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
33
|
+
- **Attacker capabilities:** Who is the attacker, and what inputs, systems, or
|
|
34
|
+
responses can they control _without_ already having the privileges or secrets
|
|
35
|
+
they are trying to gain?
|
|
36
|
+
- **Attack path:** How does attacker-controlled input reach the affected code
|
|
37
|
+
through a supported public API or a realistic application integration?
|
|
38
|
+
- **Prerequisites:** What configuration and user actions are required? If the
|
|
39
|
+
attack depends on unusual options or deliberately malformed input, explain why
|
|
40
|
+
those conditions could arise in a real application.
|
|
41
|
+
- **Impact:** What confidentiality, integrity, or availability boundary is
|
|
42
|
+
crossed, and what can the attacker achieve as a result?
|
|
35
43
|
|
|
36
|
-
|
|
44
|
+
A vulnerability involving an optional or less common feature can still qualify
|
|
45
|
+
if these conditions are met. Conversely, the existence of a defensive check in
|
|
46
|
+
the code does not, by itself, establish that every bypass of that check has a
|
|
47
|
+
realistic security impact.
|
|
37
48
|
|
|
38
|
-
|
|
39
|
-
- The function involved (`mimeHtml`, `textToHtml`, `htmlToText`, `inlineHtml`,
|
|
40
|
-
`inlineText`).
|
|
41
|
-
- A clear description of the issue and its impact (e.g. XSS / sanitizer bypass,
|
|
42
|
-
denial of service via catastrophic regex backtracking or CSS that hangs
|
|
43
|
-
processing, prototype pollution, content or information disclosure).
|
|
44
|
-
- A minimal proof of concept: the input that triggers it and the unsafe output
|
|
45
|
-
or behavior it produces.
|
|
46
|
-
- Any suggested remediation, if you have one.
|
|
49
|
+
## Reporting a Vulnerability
|
|
47
50
|
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
reporters who wish to be named are credited.
|
|
51
|
+
**Do not disclose suspected exploitable vulnerabilities through public GitHub
|
|
52
|
+
issues, pull requests, or discussions before coordinating with the
|
|
53
|
+
maintainers.**
|
|
52
54
|
|
|
53
|
-
|
|
55
|
+
Report privately through one of the following channels:
|
|
54
56
|
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
57
|
+
1. **GitHub Security Advisories (preferred):**
|
|
58
|
+
<https://github.com/postalsys/email-text-tools/security/advisories/new>.
|
|
59
|
+
2. **Email:** **andris@postalsys.com**. Encrypt sensitive details if possible
|
|
60
|
+
(PGP key fingerprint `5D952A46E1D8C931F6364E01DC6C83F4D584D364`).
|
|
61
|
+
|
|
62
|
+
### Required Information
|
|
63
|
+
|
|
64
|
+
Please provide enough information to evaluate both the defect and its security
|
|
65
|
+
impact. Reports should include:
|
|
66
|
+
|
|
67
|
+
1. The affected `@postalsys/email-text-tools` version or commit, Node.js
|
|
68
|
+
version, and relevant configuration.
|
|
69
|
+
2. A concise description of the issue and the affected public API or code path
|
|
70
|
+
(for example `mimeHtml`, `textToHtml`, `htmlToText`, `inlineHtml`, or
|
|
71
|
+
`inlineText`, with the input that triggers the issue and the unsafe output or
|
|
72
|
+
behavior it produces).
|
|
73
|
+
3. A minimal, tested reproduction, including steps to run it, expected behavior,
|
|
74
|
+
and observed behavior.
|
|
75
|
+
4. A concrete threat model: attacker control, prerequisites, trust boundary, and
|
|
76
|
+
resulting impact. Clearly distinguish what your reproduction proves from what
|
|
77
|
+
you believe might be possible.
|
|
78
|
+
5. An explanation of why the issue affects real deployments beyond a
|
|
79
|
+
deliberately constructed test setup, where this is not obvious.
|
|
80
|
+
|
|
81
|
+
A suggested fix is welcome but does not replace an explanation of
|
|
82
|
+
exploitability. A complete real-world exploit is not always necessary, but the
|
|
83
|
+
report must make a credible security impact clear.
|
|
84
|
+
|
|
85
|
+
### Reports That May Be Treated as Ordinary Bugs
|
|
86
|
+
|
|
87
|
+
The following generally do **not** qualify for private security handling unless
|
|
88
|
+
you can demonstrate an additional, meaningful security boundary crossing:
|
|
89
|
+
|
|
90
|
+
- Issues that require the attacker to control trusted application code,
|
|
91
|
+
administrator-only configuration, or the secret they supposedly extract.
|
|
92
|
+
- Problems caused solely by application-level misuse, exposed credentials, or
|
|
93
|
+
insecure deployment choices outside `@postalsys/email-text-tools`'s control.
|
|
94
|
+
- Contrived proof-of-concept setups where the tester controls both sides of a
|
|
95
|
+
request, without explaining how a separate attacker could trigger the issue.
|
|
96
|
+
- Parser quirks, unexpected behavior, and bypasses of internal checks with no
|
|
97
|
+
demonstrated security impact.
|
|
98
|
+
- Speculative findings based only on static analysis or an automated tool's
|
|
99
|
+
assessment, without a verified reproduction and credible attack scenario.
|
|
100
|
+
|
|
101
|
+
These may still be valid bugs and may be considered through the normal issue
|
|
102
|
+
tracker. Please coordinate before making any potentially exploitable details
|
|
103
|
+
public. Classification as a bug does not guarantee a fix or a particular
|
|
104
|
+
priority.
|
|
105
|
+
|
|
106
|
+
### Automated and AI-Assisted Reports
|
|
107
|
+
|
|
108
|
+
Automated analysis and AI tools are welcome as research aids, but the person
|
|
109
|
+
submitting a report is responsible for verifying its claims. **Do not submit
|
|
110
|
+
bulk, unverified, or speculative AI-generated findings.** Test each finding
|
|
111
|
+
against a supported release and establish the actual security impact. Reports
|
|
112
|
+
that do not meet the requirements above may be closed without further
|
|
113
|
+
investigation or individual feedback; they can be resubmitted with stronger
|
|
114
|
+
evidence.
|
|
115
|
+
|
|
116
|
+
## Triage and Disclosure
|
|
117
|
+
|
|
118
|
+
`@postalsys/email-text-tools` is maintained by a small team, and there is **no
|
|
119
|
+
guaranteed response or resolution time**. Reports are prioritized based on
|
|
120
|
+
demonstrated impact, exploitability, affected usage, and available maintenance
|
|
121
|
+
resources.
|
|
122
|
+
|
|
123
|
+
A private report does not automatically become a security advisory. Confirmed
|
|
124
|
+
vulnerabilities may be fixed and disclosed through GitHub Security Advisories;
|
|
125
|
+
other findings may be closed, deferred, or handled as ordinary bugs. Please do
|
|
126
|
+
not disclose details of an unresolved, potentially exploitable issue publicly
|
|
127
|
+
without coordinating with the maintainers.
|
|
128
|
+
|
|
129
|
+
## CVEs and Credit
|
|
130
|
+
|
|
131
|
+
We do not request or manage CVE identifiers. A report being acknowledged, a bug
|
|
132
|
+
being fixed, or a pull request being merged does **not** mean that
|
|
133
|
+
`@postalsys/email-text-tools` has confirmed a security vulnerability or endorsed
|
|
134
|
+
a CVE assignment. We do not guarantee advisories, CVE identifiers, or public
|
|
135
|
+
credit for reports. For confirmed vulnerabilities disclosed through an advisory,
|
|
136
|
+
substantive reporters may be credited if they wish.
|
|
59
137
|
|
|
60
138
|
## Scope
|
|
61
139
|
|
|
62
|
-
In scope: the library source in this repository
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
regex backtracking or makes CSS inlining hang or exhaust resources.
|
|
69
|
-
- Prototype pollution or similar object-integrity issues reachable through the
|
|
70
|
-
public API.
|
|
140
|
+
In scope: the library source in this repository, in particular sanitizer
|
|
141
|
+
bypasses in `mimeHtml` that let active content (scripts, event handler
|
|
142
|
+
attributes, dangerous URL schemes, or other executable markup) survive into the
|
|
143
|
+
sanitized output, denial of service in any conversion path from catastrophic
|
|
144
|
+
regex backtracking or CSS inlining that hangs or exhausts resources, and
|
|
145
|
+
prototype pollution reachable through the public API.
|
|
71
146
|
|
|
72
147
|
Out of scope:
|
|
73
148
|
|
|
74
|
-
- Vulnerabilities in your own application that consumes this library
|
|
75
|
-
example
|
|
149
|
+
- Vulnerabilities in your own application that consumes this library, for
|
|
150
|
+
example rendering the output without a Content Security Policy, or trusting
|
|
76
151
|
the output in a non-HTML context.
|
|
77
152
|
- Issues in third-party dependencies that are already publicly known; report
|
|
78
153
|
those upstream (we will still pick up the dependency fix in a release).
|
|
79
|
-
-
|
|
154
|
+
- Social-engineering reports.
|
|
80
155
|
|
|
81
|
-
Thank you for helping keep email-text-tools and its users safe.
|
|
156
|
+
Thank you for helping keep `@postalsys/email-text-tools` and its users safe.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@postalsys/email-text-tools",
|
|
3
|
-
"version": "2.4.
|
|
3
|
+
"version": "2.4.19",
|
|
4
4
|
"description": "Email text tools",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"scripts": {
|
|
@@ -29,12 +29,12 @@
|
|
|
29
29
|
"homepage": "https://github.com/postalsys/email-text-tools#readme",
|
|
30
30
|
"devDependencies": {
|
|
31
31
|
"@eslint/js": "10.0.1",
|
|
32
|
-
"eslint": "10.
|
|
32
|
+
"eslint": "10.12.0",
|
|
33
33
|
"eslint-config-prettier": "10.1.8",
|
|
34
|
-
"prettier": "3.9.
|
|
34
|
+
"prettier": "3.9.10"
|
|
35
35
|
},
|
|
36
36
|
"dependencies": {
|
|
37
|
-
"dompurify": "3.4.
|
|
37
|
+
"dompurify": "3.4.17",
|
|
38
38
|
"he": "1.2.0",
|
|
39
39
|
"html-to-text": "10.0.1",
|
|
40
40
|
"jsdom": "27.0.0",
|