-
Notifications
You must be signed in to change notification settings - Fork 17
Open
Description
Running Cyrus JMAP 3.12.0 I get:
[nix-shell:/tmp/mujmap]$ ./target/debug/mujmap -C ~/Maildir/sander/ sync
error: Could not sync mail: Could not open remote session: Could not open session at https://jmap.<domain>/.well-known/jmap: https://jmap.<domain>/jmap: status code 401
[nix-shell:/tmp/mujmap]$ ./target/debug/mujmap -vv -C ~/Maildir/sander/ sync 2>&1 | grep offered
[2025-05-25T18:50:29Z DEBUG mujmap::remote] server offered unsupported auth scheme: Negotiate
Caddy:
"resp_headers": {
[..]
"Www-Authenticate": [
"Negotiate",
"SCRAM-SHA-256 realm=\"otter\"",
"SCRAM-SHA-1 realm=\"otter\"",
"Basic realm=\"otter\""
],
[..]
}
If I patch src/remote.rs with:
diff --git a/src/remote.rs b/src/remote.rs
index 7829255..3d7c88d 100644
--- a/src/remote.rs
+++ b/src/remote.rs
@@ -285,6 +285,11 @@ impl Remote {
Some(encode_basic(username, password))
}
+ Some(v) if v.starts_with("Negotiate") => {
+ debug!("server offered Negotiate auth");
+ Some(encode_basic(username, password))
+ }
+
Some(v) if v.starts_with("Bearer") => {
debug!("server offered Bearer auth");
Some(format!("Bearer {}", password))
I get:
$ mujmap -C ~/Maildir/sander/ sync
Retrieving metadata... (0 possibly changed)
Applying changes to notmuch database... (0 new, 0 changed, 0 destroyed)
Applying changes to JMAP server... (0 changed)
$ mujmap -vv -C ~/Maildir/sander/ sync 2>&1 | grep offered
[2025-05-25T18:52:23Z DEBUG mujmap::remote] server offered Negotiate auth
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels