mirror of
https://github.com/chatmail/core.git
synced 2026-05-07 17:06:35 +03:00
Merge branch 'master' into flub/send-backup
This commit is contained in:
@@ -10,6 +10,7 @@
|
|||||||
- Use transaction in `update_blocked_mailinglist_contacts`. #4058
|
- Use transaction in `update_blocked_mailinglist_contacts`. #4058
|
||||||
- Remove `Sql.get_conn()` interface in favor of `.call()` and `.transaction()`. #4055
|
- Remove `Sql.get_conn()` interface in favor of `.call()` and `.transaction()`. #4055
|
||||||
- Updated provider database.
|
- Updated provider database.
|
||||||
|
- Disable DKIM-Checks again #4076
|
||||||
- ability to send backup over network and QR code to setup second device #4007
|
- ability to send backup over network and QR code to setup second device #4007
|
||||||
|
|
||||||
### Fixes
|
### Fixes
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
#![warn(unused, clippy::all)]
|
#![warn(unused, clippy::all, clippy::missing_docs_in_private_items)]
|
||||||
#![allow(
|
#![allow(
|
||||||
non_camel_case_types,
|
non_camel_case_types,
|
||||||
non_snake_case,
|
non_snake_case,
|
||||||
|
|||||||
@@ -644,6 +644,7 @@ Authentication-Results: dkim=";
|
|||||||
.unwrap();
|
.unwrap();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#[ignore = "Disallowing keychanges is disabled for now"]
|
||||||
#[tokio::test(flavor = "multi_thread", worker_threads = 2)]
|
#[tokio::test(flavor = "multi_thread", worker_threads = 2)]
|
||||||
async fn test_handle_authres_fails() -> Result<()> {
|
async fn test_handle_authres_fails() -> Result<()> {
|
||||||
let mut tcm = TestContextManager::new();
|
let mut tcm = TestContextManager::new();
|
||||||
@@ -821,7 +822,8 @@ Authentication-Results: dkim=";
|
|||||||
.insert_str(0, "Authentication-Results: example.net; dkim=fail\n");
|
.insert_str(0, "Authentication-Results: example.net; dkim=fail\n");
|
||||||
let rcvd = bob.recv_msg(&sent).await;
|
let rcvd = bob.recv_msg(&sent).await;
|
||||||
|
|
||||||
assert!(rcvd.error.unwrap().contains("DKIM failed"));
|
// Disallowing keychanges is disabled for now:
|
||||||
|
// assert!(rcvd.error.unwrap().contains("DKIM failed"));
|
||||||
// The message info should contain a warning:
|
// The message info should contain a warning:
|
||||||
assert!(message::get_msg_info(&bob, rcvd.id)
|
assert!(message::get_msg_info(&bob, rcvd.id)
|
||||||
.await
|
.await
|
||||||
|
|||||||
@@ -99,7 +99,8 @@ pub(crate) async fn prepare_decryption(
|
|||||||
from,
|
from,
|
||||||
autocrypt_header.as_ref(),
|
autocrypt_header.as_ref(),
|
||||||
message_time,
|
message_time,
|
||||||
dkim_results.allow_keychange,
|
// Disallowing keychanges is disabled for now:
|
||||||
|
true, // dkim_results.allow_keychange,
|
||||||
)
|
)
|
||||||
.await?;
|
.await?;
|
||||||
|
|
||||||
|
|||||||
@@ -342,7 +342,8 @@ impl MimeMessage {
|
|||||||
if let (Some(peerstate), Ok(mail)) = (&mut decryption_info.peerstate, mail) {
|
if let (Some(peerstate), Ok(mail)) = (&mut decryption_info.peerstate, mail) {
|
||||||
if message_time > peerstate.last_seen_autocrypt
|
if message_time > peerstate.last_seen_autocrypt
|
||||||
&& mail.ctype.mimetype != "multipart/report"
|
&& mail.ctype.mimetype != "multipart/report"
|
||||||
&& decryption_info.dkim_results.allow_keychange
|
// Disallowing keychanges is disabled for now:
|
||||||
|
// && decryption_info.dkim_results.allow_keychange
|
||||||
{
|
{
|
||||||
peerstate.degrade_encryption(message_time);
|
peerstate.degrade_encryption(message_time);
|
||||||
}
|
}
|
||||||
@@ -413,11 +414,12 @@ impl MimeMessage {
|
|||||||
parser.heuristically_parse_ndn(context).await;
|
parser.heuristically_parse_ndn(context).await;
|
||||||
parser.parse_headers(context).await?;
|
parser.parse_headers(context).await?;
|
||||||
|
|
||||||
if !parser.decryption_info.dkim_results.allow_keychange {
|
// Disallowing keychanges is disabled for now
|
||||||
for part in parser.parts.iter_mut() {
|
// if !decryption_info.dkim_results.allow_keychange {
|
||||||
part.error = Some("Seems like DKIM failed, this either is an attack or (more likely) a bug in Authentication-Results checking. Please tell us about this at https://support.delta.chat.".to_string());
|
// for part in parser.parts.iter_mut() {
|
||||||
}
|
// part.error = Some("Seems like DKIM failed, this either is an attack or (more likely) a bug in Authentication-Results checking. Please tell us about this at https://support.delta.chat.".to_string());
|
||||||
}
|
// }
|
||||||
|
// }
|
||||||
|
|
||||||
if parser.is_mime_modified {
|
if parser.is_mime_modified {
|
||||||
parser.decoded_data = mail_raw;
|
parser.decoded_data = mail_raw;
|
||||||
|
|||||||
@@ -688,6 +688,10 @@ pub(crate) async fn maybe_do_aeap_transition(
|
|||||||
Ok(())
|
Ok(())
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// Type of the peerstate change.
|
||||||
|
///
|
||||||
|
/// Changes to the peerstate are notified to the user via a message
|
||||||
|
/// explaining the happened change.
|
||||||
enum PeerstateChange {
|
enum PeerstateChange {
|
||||||
/// The contact's public key fingerprint changed, likely because
|
/// The contact's public key fingerprint changed, likely because
|
||||||
/// the contact uses a new device and didn't transfer their key.
|
/// the contact uses a new device and didn't transfer their key.
|
||||||
|
|||||||
Reference in New Issue
Block a user