jakartaee / jakartaee/mail-api

Wrong charset used in creating search terms when server supports UTF8

Open
#474 2 comments 0 reactions 1 assignee Claimed by @jmehrens View on GitHub
bug
Dominant language
Java
Stars
285
Forks
109
Avg merge
15h 19m
Merged PRs (30d)
1

Description

**Describe the bug**
Function `int[] search(String msgSequence, SearchTerm term) throws ProtocolException, SearchException` on line 2479 in `IMAPProtocol` class checks if server support UTF8.
In function `private int[] issueSearch(String msgSequence, SearchTerm term, String charset) throws ProtocolException, SearchException, IOException` on line 2532 `Argument` object is created with charset as null.

When null is passed to `SearchSequence#generateSequence()` it defaults to all ASCII text while parsing strings in seach terms.

I don't know if reproduction is needed here.

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.