imapflow 2.4.0 → 2.4.2

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/CHANGELOG.md CHANGED
@@ -1,5 +1,19 @@
1
1
  # Changelog
2
2
 
3
+ ## [2.4.2](https://github.com/postalsys/imapflow/compare/v2.4.1...v2.4.2) (2026-10-14)
4
+
5
+
6
+ ### Bug Fixes
7
+
8
+ * **deps:** update libmime to 5.4.8 and mailsplit to 5.4.21 ([8eafb46](https://github.com/postalsys/imapflow/commit/8eafb46f858893670dda1be115899b8b761391ab))
9
+
10
+ ## [2.4.1](https://github.com/postalsys/imapflow/compare/v2.4.0...v2.4.1) (2026-10-14)
11
+
12
+
13
+ ### Bug Fixes
14
+
15
+ * **download:** bump libbase64 to decode padded base64 parts in linear memory ([1c83261](https://github.com/postalsys/imapflow/commit/1c832614dda83160de1387f08e7592add65e2779))
16
+
3
17
  ## [2.4.0](https://github.com/postalsys/imapflow/compare/v2.3.0...v2.4.0) (2026-10-10)
4
18
 
5
19
 
package/SECURITY.md CHANGED
@@ -1,88 +1,159 @@
1
1
  # Security Policy
2
2
 
3
- ImapFlow is a Node.js IMAP client library. It opens TLS/cleartext connections to
4
- IMAP servers, sends account credentials, and parses untrusted protocol responses
5
- from those servers. Because it handles credentials and processes data from
6
- remote servers that may be malicious or buggy, we take security reports
7
- seriously and aim to respond quickly.
3
+ ImapFlow is a Node.js IMAP client library. It opens TLS and cleartext
4
+ connections to IMAP servers, sends account credentials, and parses untrusted
5
+ protocol responses from servers that may be malicious or buggy. We welcome
6
+ responsible reports of vulnerabilities that present a credible security risk to
7
+ users. Please distinguish security vulnerabilities from ordinary bugs, unusual
8
+ 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 backport
12
- patches to older releases - upgrading to the current release line is the
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
- | 1.x | :white_check_mark: |
18
- | < 1.0 | :x: |
18
+ | 2.x | :white_check_mark: |
19
+ | < 2.0 | :x: |
19
20
 
20
- If you are on an older version, please upgrade. See the release notes at
21
+ If you are on an older major, please upgrade. See the release notes at
21
22
  <https://github.com/postalsys/imapflow/releases> before updating.
22
23
 
24
+ ## What Qualifies as a Security Vulnerability
25
+
26
+ A security report should identify a realistic way for an attacker to cross a
27
+ security boundary in a supported version of ImapFlow. Unexpected behavior, a
28
+ failing test, or a technically correct proof of concept is not sufficient on its
29
+ own to establish security impact.
30
+
31
+ In particular, explain:
32
+
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?
43
+
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.
48
+
23
49
  ## Reporting a Vulnerability
24
50
 
25
- **Please do not report security vulnerabilities through public GitHub issues,
26
- pull requests, or discussions.**
51
+ **Do not disclose suspected exploitable vulnerabilities through public GitHub
52
+ issues, pull requests, or discussions before coordinating with the
53
+ maintainers.**
27
54
 
28
55
  Report privately through one of the following channels:
29
56
 
30
- 1. **GitHub Security Advisories (preferred).** Open a private report at
31
- <https://github.com/postalsys/imapflow/security/advisories/new>. This keeps
32
- the discussion private until a fix is published and lets us credit you.
33
- 2. **Email.** Send details to **andris@postalsys.com** (the contact listed in
34
- [`SECURITY.txt`](SECURITY.txt)). Encrypt sensitive details with the PGP key
35
- referenced there if possible.
36
-
37
- When reporting, please include as much of the following as you can:
38
-
39
- - The affected version(s) and environment (ImapFlow version, Node.js version,
40
- OS).
41
- - The component involved (e.g. the IMAP response stream/parser, literal and line
42
- handling, TLS/STARTTLS upgrade, credential handling, the command compiler, or
43
- the public client API).
44
- - A clear description of the issue and its impact (e.g. memory exhaustion or
45
- denial of service from a malicious server, parser crash, credential
46
- disclosure, TLS verification bypass, injection into the IMAP command stream,
47
- prototype pollution, information disclosure).
48
- - A minimal proof of concept or reproduction steps - ideally a sample server
49
- response or a short script that triggers the issue.
50
- - Any suggested remediation, if you have one.
51
-
52
- We are a small team, so there is no guaranteed response time - sometimes reports
53
- are handled within hours, sometimes they take longer. Accepted issues are fixed
54
- in a new release and coordinated through a GitHub Security Advisory, and
55
- reporters who wish to be named are credited.
56
-
57
- ## CVEs
58
-
59
- We track and disclose vulnerabilities through GitHub Security Advisories. We do
60
- not request or manage CVE identifiers ourselves. If you need a CVE assigned for a
61
- reported issue, please request one yourself - for example, through GitHub's own
62
- CVE request flow on the published advisory, or another CNA.
57
+ 1. **GitHub Security Advisories (preferred):**
58
+ <https://github.com/postalsys/imapflow/security/advisories/new>.
59
+ 2. **Email:** **andris@postalsys.com**, as listed in
60
+ [`SECURITY.txt`](SECURITY.txt). Encrypt sensitive details if possible.
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 ImapFlow version or commit, Node.js version, and relevant
68
+ configuration.
69
+ 2. A concise description of the issue and the affected public API or code path
70
+ (for example the IMAP response stream and parser, literal and line handling,
71
+ the TLS/STARTTLS upgrade, credential handling, the command compiler, or the
72
+ public client API. A sample server response is often the most useful
73
+ reproduction).
74
+ 3. A minimal, tested reproduction, including steps to run it, expected behavior,
75
+ and observed behavior.
76
+ 4. A concrete threat model: attacker control, prerequisites, trust boundary, and
77
+ resulting impact. Clearly distinguish what your reproduction proves from what
78
+ you believe might be possible.
79
+ 5. An explanation of why the issue affects real deployments beyond a
80
+ deliberately constructed test setup, where this is not obvious.
81
+
82
+ A suggested fix is welcome but does not replace an explanation of
83
+ exploitability. A complete real-world exploit is not always necessary, but the
84
+ report must make a credible security impact clear.
85
+
86
+ ### Reports That May Be Treated as Ordinary Bugs
87
+
88
+ The following generally do **not** qualify for private security handling unless
89
+ you can demonstrate an additional, meaningful security boundary crossing:
90
+
91
+ - Issues that require the attacker to control trusted application code,
92
+ administrator-only configuration, or the secret they supposedly extract.
93
+ - Problems caused solely by application-level misuse, exposed credentials, or
94
+ insecure deployment choices outside ImapFlow's control.
95
+ - Contrived proof-of-concept setups where the tester controls both sides of a
96
+ request, without explaining how a separate attacker could trigger the issue.
97
+ - Parser quirks, unexpected behavior, and bypasses of internal checks with no
98
+ demonstrated security impact.
99
+ - Speculative findings based only on static analysis or an automated tool's
100
+ assessment, without a verified reproduction and credible attack scenario.
101
+
102
+ These may still be valid bugs and may be considered through the normal issue
103
+ tracker. Please coordinate before making any potentially exploitable details
104
+ public. Classification as a bug does not guarantee a fix or a particular
105
+ priority.
106
+
107
+ ### Automated and AI-Assisted Reports
108
+
109
+ Automated analysis and AI tools are welcome as research aids, but the person
110
+ submitting a report is responsible for verifying its claims. **Do not submit
111
+ bulk, unverified, or speculative AI-generated findings.** Test each finding
112
+ against a supported release and establish the actual security impact. Reports
113
+ that do not meet the requirements above may be closed without further
114
+ investigation or individual feedback; they can be resubmitted with stronger
115
+ evidence.
116
+
117
+ ## Triage and Disclosure
118
+
119
+ ImapFlow is maintained by a small team, and there is **no guaranteed response or
120
+ resolution time**. Reports are prioritized based on demonstrated impact,
121
+ exploitability, affected usage, and available maintenance 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 ImapFlow has
133
+ confirmed a security vulnerability or endorsed a CVE assignment. We do not
134
+ guarantee advisories, CVE identifiers, or public credit for reports. For
135
+ confirmed vulnerabilities disclosed through an advisory, substantive reporters
136
+ may be credited if they wish.
63
137
 
64
138
  ## Scope
65
139
 
66
- In scope: the ImapFlow library source in this repository - the IMAP response
140
+ In scope: the ImapFlow library source in this repository: the IMAP response
67
141
  stream and token parser (including handling of hostile or malformed server
68
- responses, literals, line lengths, and resource/DoS bounds), the TLS and
69
- STARTTLS upgrade path and certificate handling, credential handling during
142
+ responses, literals, line lengths, and resource bounds), the TLS and STARTTLS
143
+ upgrade path and certificate handling, credential handling during
70
144
  authentication, the command compiler that builds outgoing IMAP commands, and the
71
145
  public client API.
72
146
 
73
147
  Out of scope:
74
148
 
75
149
  - Vulnerabilities in your own application code that uses ImapFlow.
76
- - Misconfiguration of your usage - for example, disabling TLS certificate
150
+ - Misconfiguration of your usage, for example disabling TLS certificate
77
151
  verification (`tls.rejectUnauthorized: false`), connecting over cleartext when
78
152
  TLS is available, or passing untrusted input directly into mailbox paths or
79
153
  command arguments without validation.
80
- - Vulnerabilities in the IMAP servers you connect to, or in third-party
81
- dependencies (please report those to their respective maintainers; we will
82
- upgrade once a fix is available).
154
+ - Vulnerabilities in the IMAP servers you connect to.
83
155
  - Issues that require an already-compromised host or local access to the machine
84
156
  running ImapFlow.
85
- - Social-engineering reports and theoretical issues without a demonstrated,
86
- concrete impact.
157
+ - Social-engineering reports.
87
158
 
88
159
  Thank you for helping keep ImapFlow and its users safe.
@@ -1,3 +1,3 @@
1
1
  export declare const name = "imapflow";
2
- export declare const version = "2.4.0";
2
+ export declare const version = "2.4.2";
3
3
  export declare const homepage = "https://imapflow.com/";
@@ -3,5 +3,5 @@
3
3
  Object.defineProperty(exports, "__esModule", { value: true });
4
4
  exports.homepage = exports.version = exports.name = void 0;
5
5
  exports.name = "imapflow";
6
- exports.version = "2.4.0";
6
+ exports.version = "2.4.2";
7
7
  exports.homepage = "https://imapflow.com/";
@@ -1,3 +1,3 @@
1
1
  export declare const name = "imapflow";
2
- export declare const version = "2.4.0";
2
+ export declare const version = "2.4.2";
3
3
  export declare const homepage = "https://imapflow.com/";
@@ -1,4 +1,4 @@
1
1
  // Generated by scripts/build.js from package.json. Do not edit by hand.
2
2
  export const name = "imapflow";
3
- export const version = "2.4.0";
3
+ export const version = "2.4.2";
4
4
  export const homepage = "https://imapflow.com/";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "imapflow",
3
- "version": "2.4.0",
3
+ "version": "2.4.2",
4
4
  "description": "IMAP Client for Node",
5
5
  "type": "module",
6
6
  "main": "./dist/cjs/imap-flow.js",
@@ -76,19 +76,19 @@
76
76
  "eslint-config-prettier": "10.1.8",
77
77
  "globals": "17.13.0",
78
78
  "imapkit": "5.0.1",
79
- "prettier": "3.9.9",
79
+ "prettier": "3.9.10",
80
80
  "tsx": "4.23.15",
81
81
  "types-node-legacy": "npm:@types/node@20.0.0",
82
82
  "typescript": "6.0.3",
83
- "typescript-eslint": "8.71.1",
84
- "wrangler": "4.149.0"
83
+ "typescript-eslint": "8.71.2",
84
+ "wrangler": "4.151.0"
85
85
  },
86
86
  "dependencies": {
87
- "@zone-eu/mailsplit": "5.4.20",
87
+ "@zone-eu/mailsplit": "5.4.21",
88
88
  "encoding-japanese": "2.4.0",
89
89
  "iconv-lite": "0.7.3",
90
- "libbase64": "1.3.2",
91
- "libmime": "5.4.7",
90
+ "libbase64": "1.3.3",
91
+ "libmime": "5.4.8",
92
92
  "libqp": "2.1.2",
93
93
  "pino": "10.3.1",
94
94
  "socks": "2.8.10"