Skip to content

Navigation Menu

Sign in
Sign up

Commit 0eac4e8

Browse files
committed
Merge testing into master for v8.0.3 release
2 parents 8209ac2 + d537871 commit 0eac4e8

26 files changed

Lines changed: 499 additions & 183 deletions

‎.github/workflows/publish.yml‎

Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,59 @@
1+
name: Publish to PyPI
2+
3+
on:
4+
workflow_dispatch:
5+
push:
6+
tags:
7+
- 'v*'
8+
9+
10+
11+
permissions:
12+
contents: read
13+
14+
jobs:
15+
build:
16+
name: Build distribution
17+
runs-on: ubuntu-latest
18+
19+
steps:
20+
- uses: actions/checkout@v4
21+
22+
- name: Set up Python
23+
uses: actions/setup-python@v5
24+
with:
25+
python-version: '3.x'
26+
27+
- name: Install build dependencies
28+
run: |
29+
python -m pip install --upgrade pip
30+
pip install build
31+
32+
- name: Build package
33+
run: python -m build
34+
35+
- name: Upload distribution artifacts
36+
uses: actions/upload-artifact@v4
37+
with:
38+
name: dist
39+
path: dist/
40+
41+
publish:
42+
name: Publish to PyPI
43+
needs: build
44+
runs-on: ubuntu-latest
45+
environment:
46+
name: pypi
47+
url: https://pypi.org/p/offlineimap
48+
permissions:
49+
id-token: write # Required for Trusted Publishers (OIDC)
50+
51+
steps:
52+
- name: Download distribution artifacts
53+
uses: actions/download-artifact@v4
54+
with:
55+
name: dist
56+
path: dist/
57+
58+
- name: Publish package to PyPI
59+
uses: pypa/gh-action-pypi-publish@release/v1

‎.travis.yml‎

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,14 @@
11
language: python
22
python:
3-
- '2.7'
3+
- '3.6'
4+
- '3.7'
5+
- '3.8'
6+
- '3.9'
7+
- '3.10'
8+
- '3.11'
9+
- '3.12'
10+
- '3.13'
11+
dist: jammy
412
notifications:
513
webhooks:
614
urls:
@@ -25,10 +33,10 @@ matrix:
2533
include:
2634
- os: osx
2735
language: generic
28-
env: PYTHON=2.7.14 OUTLOOK_AUTH=PLAIN GMAIL_AUTH=XOAUTH2
36+
env: PYTHON=3.12.0 OUTLOOK_AUTH=PLAIN GMAIL_AUTH=XOAUTH2
2937
- os: osx
3038
language: generic
31-
env: PYTHON=2.7.14 OUTLOOK_AUTH=LOGIN GMAIL_AUTH=XOAUTH2
39+
env: PYTHON=3.12.0 OUTLOOK_AUTH=LOGIN GMAIL_AUTH=XOAUTH2
3240
allow_failures:
3341
- os: osx
3442
cache: pip

‎CODE_OF_CONDUCT.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11

22
# Realistic Code of Conduct
33

4-
1. We mostly care about making our softwares better.
4+
1. We mostly care about making our software better.
55

66
2. Everybody is free to decide how to contribute.
77

‎Changelog.md‎

Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,55 @@ Note to mainainers:
1515
* The following excerpt is only usefull when rendered in the website.
1616
{:toc}
1717

18+
### OfflineIMAP v8.0.3 (2026年06月08日)
19+
20+
**Notes**
21+
22+
Rodolfo García Peñas (kix): To my father, with love. Rest in peace, Dad.
23+
24+
This release focuses on security hardening, deadlock prevention, and robustness improvements. A TLS-stripping attack vector when using STARTTLS has been closed, a deadlock in connection teardown has been fixed, and several crash and encoding edge cases have been resolved.
25+
26+
#### Security
27+
28+
- **Fix TLS-stripping attack on STARTTLS**: When `starttls = yes`, a MITM attacker could remove the `STARTTLS` capability from the server greeting, causing offlineimap to silently skip TLS negotiation and send credentials in plaintext. The connection now aborts if STARTTLS is expected but not offered. (Fixes #222)
29+
30+
- **Fallback for non-standard STARTTLS capability handling**: Some servers do not re-advertise capabilities after the TLS handshake in the expected way. A configurable `allow_nonstandard_capabilities` option has been added to tolerate this without compromising security. (Fixes #242)
31+
32+
#### Bug Fixes
33+
34+
- **Prevent deadlock in `IMAPServer.close()`**: Calling `close()` while `maxsyncaccounts` or `maxconnections` > 1 could deadlock. The semaphore reset now happens outside the `connectionlock`. (Fixes #241)
35+
36+
- **Retry connection on dead socket during authentication**: When an auth method fails due to a dead socket, the connection is re-established and the remaining auth methods are retried instead of failing immediately.
37+
38+
- **Fix `UnicodeEncodeError` on emails with malformed bytes**: Message bodies with bytes that cannot be encoded in the local charset are now handled gracefully. (Fixes #239)
39+
40+
- **Use correct IMAP folder name in `imapobj.select`**: The encoded mailbox name is now passed correctly, fixing sync failures with non-ASCII folder names.
41+
42+
- **Reevaluate `oauth2_access_token_eval` on every connection**: The OAuth2 access token getter is now called on each `acquireconnection()` call, ensuring expired tokens are refreshed. (Fixes #244)
43+
44+
- **Fix `Blinkenlights` UI crash**: The `isusable()` method had a wrong signature (`cls` instead of `self`) that caused an `AttributeError` at startup. The ncurses availability check has also been simplified.
45+
46+
- **Handle exceptions from the IMAP `ID` command**: Servers that do not support the `ID` extension or return an error no longer crash the sync.
47+
48+
- **Handle errors reading `remotepassfile` gracefully**: A missing or unreadable password file now produces a clear error instead of a traceback.
49+
50+
#### Changes
51+
52+
- **Make folder name encoding conditional on `utf8foldernames`**: IMAP folder name encoding via `encode_mailbox_name` is now only applied when `utf8foldernames = yes`, preventing double-encoding for servers that do not require it.
53+
54+
- **Replace deprecated `platform.linux_distribution`** with the `distro` library in OS SSL certificate path detection.
55+
56+
- **GitHub Actions workflow for PyPI publishing**: Automated release publishing to PyPI on tagged commits.
57+
58+
#### Authors
59+
60+
- Rodolfo García Peñas (kix) (30)
61+
- Noa Torstensvik (1)
62+
- Michael Hohmuth (1)
63+
- Derek Schrock (1)
64+
- Andreas Schacker (1)
65+
66+
1867
### OfflineIMAP v8.0.2 (2026年04月11日)
1968

2069
**Notes**

‎README.md‎

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ If you are running Linux/BSD, you can install offlineimap with:
6969
- Fedora `dnf install offlineimap`
7070
- FreeBSD `pkg search offlineimap3`, and install the python versioned package, `pkg install py311-offlineimap3`
7171
- Arch Linux: [`pacman -S offlineimap`](https://archlinux.org/packages/extra/any/offlineimap/), or through AUR package [offlineimap3-git](https://aur.archlinux.org/packages/offlineimap3-git/)
72-
- Docker image: `offlineimap/offlineimap:latest`
72+
- Docker image: `offlineimap/offlineimap:latest`
7373
(note: image not published yet, just an example)
7474

7575
## Feedbacks and contributions
@@ -100,12 +100,15 @@ Bugs, issues and contributions can be requested to both the mailing list or the
100100

101101
## Requirements & dependencies
102102

103-
* Python v3+
103+
* Python v3.6+
104104
* rfc6555 (required)
105-
* imaplib2 >= 3.5
106-
* keyring
105+
* imaplib2 >= 3.5 (required)
106+
* keyring (optional), for storing passwords in a secure way
107107
* gssapi (optional), for Kerberos authentication
108+
* pysocks (optional), for proxy support
108109
* portalocker (optional), if you need to run offlineimap in Cygwin for Windows
110+
* certify (optional), for Internet SSL certificate validation
111+
* urllib3 (optional), for Internet SSL certificate validation
109112

110113
## Documentation
111114

‎contrib/release.py‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -279,7 +279,7 @@ def updateAPI(self):
279279
except:
280280
print(("""
281281
Oops! you don't have {} installed?"
282-
Cannot update the webite documentation..."
282+
Cannot update the website documentation..."
283283
You should install it and manually run:"
284284
$ cd {}"
285285
$ make websitedoc"

‎contrib/release.sh‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,7 @@ function changelog_template_part1 () {
186186
cat <<EOF
187187
// vim: expandtab ts=2 syntax=markdown
188188
189-
// WARNING: let at least one empy line before the real content.
189+
// WARNING: let at least one empty line before the real content.
190190
//
191191
// Write a new Changelog entry.
192192
//
@@ -319,7 +319,7 @@ function update_website () {
319319
if test ! $? -eq 0
320320
then
321321
echo "Oops! you don't have $SPHINXBUILD installed?"
322-
echo "Cannot update the webite documentation..."
322+
echo "Cannot update the website documentation..."
323323
echo "You should install it and run:"
324324
echo " $ cd docs"
325325
echo " $ make websitedoc"

‎contrib/store-pw-with-gpg/offlineimaprc.sample‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ localrepository = account2-local
2020
remoterepository = account2-remote
2121
status_backend = sqlite
2222

23-
# thi sis a gmail account
23+
# this is a gmail account
2424
[Repository account1-local]
2525
type = Maildir
2626
# create with maildirmake or by hand by creating cur, new, tmp

‎docs/offlineimap.txt‎

Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ Synchronize the accounts configured in the configuration file via IMAP. Each
1818
account has two sides. One of the side must be an IMAP server. The other side
1919
can either be a Maildir or another IMAP server.
2020

21-
Works with Python 2.
21+
Works with Python 3.
2222

2323

2424
OPTIONS
@@ -305,6 +305,24 @@ server.
305305
*DO NOT RELY ON STARTTLS AS A SAFE CONNECTION GUARANTEEING THE AUTHENTICITY OF
306306
YOUR IMAP SERVER!*
307307

308+
* allow_nonstandard_capabilities
309+
+
310+
Some non-standard IMAP servers do not send a CAPABILITY response after
311+
completing the STARTTLS handshake, as required by RFC 2595. By default,
312+
OfflineIMAP aborts with an error in this situation to avoid silently
313+
proceeding over a potentially broken encrypted channel.
314+
+
315+
Setting `allow_nonstandard_capabilities = yes` in the repository section
316+
enables a best-effort fallback: OfflineIMAP reuses the capabilities advertised
317+
before STARTTLS, removing `LOGINDISABLED`, so that authentication can continue
318+
over the (assumed) encrypted connection.
319+
+
320+
*WARNING: only enable this option when you have verified that TLS is actually
321+
established correctly.* If the server is not performing STARTTLS properly,
322+
enabling this option could cause credentials to be transmitted in plain text.
323+
+
324+
Default: `no`.
325+
308326

309327
Unix Signals
310328
------------

‎docs/website-doc.sh‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,7 @@ do
163163
echo "Usage: website-doc.sh <releases|api|contrib|usage>"
164164
;;
165165
*)
166-
echo "unkown option $arg"
166+
echo "unknown option $arg"
167167
exit_code=$(( $exit_code + 1 ))
168168
;;
169169
esac

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /