Skip to content

release: BitDM 2.1.0 - #52

Merged
Henner4746 merged 42 commits into
mainfrom
release/2.1.0
Nov 30, 2026
Merged

Henner4746 merged 42 commits into
mainfrom
release/2.1.0

Conversation

@Henner4746

Copy link
Copy Markdown
Owner

Brings everything for 2.1.0 into main in one merge. The individual PRs stay as they are; their head commits are merged here unchanged, so GitHub marks them as merged.

Included

All branches merged without textual conflicts.

Release changes

  • Version 2.1.0+24 (pubspec.yaml, fassung.dart, F-Droid recipe, README badges), CHANGELOG section, fastlane changelogs 24.txt.
  • Wallet intro now also says the wallet words are kept in the system key store, not behind the app lock.
  • New windows.yml: builds installer and zip on a GitHub Windows runner on v* tags and attaches them with a provenance attestation, same two-job pattern as linux.yml. It also builds once on PRs that change it (this one).

Server order

No changes to the attachment store. Relay: git pull (#39 truncates the WAL) plus the drop-in --ws-per-message-deflate false (#36, see secure-messenger/deploy/README.md), then restart, then tag.

🤖 Generated with Claude Code

Henner4746 and others added 30 commits October 29, 2026 18:48
bitdm.exe and the plugin DLLs import MSVCP140.dll, VCRUNTIME140.dll and
VCRUNTIME140_1.dll. A fresh Windows does not have them, so the app died
right away with 0xC0000135 STATUS_DLL_NOT_FOUND, as seen in the winget
validation on a clean sandbox (microsoft/winget-pkgs#453011). winget can
pull in the redist as a dependency; the installer and the zip from
bitdm.net and GitHub cannot.

windows/CMakeLists.txt now takes exactly these three DLLs from the
redist folder of the Visual Studio that builds (via CMake's
InstallRequiredSystemLibraries) and installs them into the Release
output for Profile/Release builds. bitdm.iss and the zip already ship
that whole folder, so both pick them up. The build fails if one of the
three is missing instead of producing a package that does not start.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Henrik wants to copy the recovery words, e.g. into a password manager,
instead of retyping or photographing them.

- A "Copy" button under the words on the 'phrase' screen after creating
  an identity and in Settings > Show recovery words (dialog). After
  copying, a note right below the button says the clipboard is cleared
  in 60 s and not to paste the words into chats or cloud notes. On the
  web the note says the browser does not always allow clearing.
- New lib/core/geheime_ablage.dart: copy through the native channel
  "bitdm/ablage" where there is one, otherwise through Flutter's
  clipboard; clear after the deadline only if the clipboard still holds
  exactly the copied text. Clears immediately when the identity is
  deleted (panic/remote wipe), not on lock (the app locks in the
  background, which is when people paste into a password manager).
- Android (GeheimeAblage.kt): ClipDescription EXTRA_IS_SENSITIVE, so the
  Android 13+ preview shows dots and keyboards do not offer it. Clearing
  runs natively because apps in the background cannot read the
  clipboard since Android 10; if it cannot read, it clears anyway.
- Windows (geheime_ablage.cpp): ExcludeClipboardContentFromMonitorProcessing,
  CanIncludeInClipboardHistory=0 and CanUploadToCloudClipboard=0, so
  neither Win+V history nor cloud clipboard keeps the words; "leere"
  empties the clipboard instead of writing an empty history entry.
- Linux (geheime_ablage.cc): offers the text plus
  x-kde-passwordManagerHint=secret via gtk_clipboard_set_with_data, so
  Klipper and similar histories skip it.
- Trust shares (Teilgeheimnisse) now copy through the same path, keeping
  their 30 s.
- Screenshot protection unchanged: both views still force it while the
  words are visible; copying does not touch it.

Tests: test/core/geheime_ablage_test.dart (deadline, foreign content
stays, Android leaves clearing to native, desktop clears via "leere"),
test/oberflaeche/woerter_kopieren_test.dart (button on 'phrase' on phone
and desktop layout, button and note inside the settings dialog, close
button unchanged, protection stays, wipe clears). Whole app suite on
Linux (CT 107): 1585 passed, 5 skipped, 1 unrelated relay timing test
under -j 4 that passes on its own. integration_test/geheime_ablage_test.dart
passed on Linux (Xvfb, xclip) and Android 15 (emulator); Windows Win32
part checked with MinGW and under Wine.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The member's client ignored every group state after leaving, so a member
the admin re-added stayed out forever: all group messages to them stayed at
one tick and the admin saw no error (QA report 2026-11-18, T1-GRP-003).

The admin now records in which version a member was added (field "j" in
the group state, schema 17 column gruppen.aufgenommen). A stale state from an
admin who has not processed the leave yet still carries the old add version
and keeps the member out, as before. A real re-add carries a version higher
than the one the member left at and brings them back. Older apps ignore the
field and keep the old behaviour.

Leaving a group now asks for confirmation first.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…rrors

On Linux the file channel has no "speichern", so the app falls back to
getDownloadsDirectory() ?? getApplicationDocumentsDirectory(). Without
xdg-user-dir the first returns null and the second throws
MissingPlatformDirectoryException. The exception reached the button
unhandled: the dialog closed, no file was written and no error was shown
(QA report 2026-11-18, T1-BAK-001).

The fallback now tries Downloads, Documents, $HOME and the app support
directory in turn, creates a named folder that does not exist yet, and only
throws if none works. The backup button shows an error instead of failing
silently.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…r takeover

After a contact linked a second device, the sender kept encrypting only to
the devices it already had a session with until the 6-hour device window
ran out, even though the new signed device list had already arrived end to
end. A newly paired tablet got nothing; a restart did not help (QA report
2026-11-18, multi-device loss).

After a lost-phone takeover it was worse: messages to device 1 went out
without to_device, so the relay delivered them to the smallest remaining
device, the replacement phone, which could not decrypt them. The sender saw
"sent".

- When a newer list of a contact names a device without a session, the
  device check is due on the next send (one check per list version).
- When such a list arrives (end to end or reloaded after "Zielgeraet
  unbekannt"), the outbox runs at once instead of on the next reconnect.
- For contacts with a signed device list, device 1 is addressed with
  to_device as well, so the relay answers "Zielgeraet unbekannt" instead of
  handing the envelope to another device.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…onnect

The relay limits each sender to 180 frames with 6 per second, and a group
message costs one frame per member device. In a 20-member group about ten
quick messages hit the limit. What was refused stayed on the clock until the
app reconnected, and every retry went to all members again, including the
ones the relay had already accepted, so it ran into the same limit (QA report
2026-11-18, burst message loss).

- _sendeAnGruppe remembers per message which members the relay accepted and
  skips them, as well as members that already sent a delivery receipt. The
  list lives in memory only; after a restart the old behaviour applies and
  receivers drop duplicates by their unique index.
- When the relay answers "zu viele Nachrichten", the outbox runs again on its
  own after 3 s, doubling up to 60 s while the relay keeps refusing and
  starting small again as soon as frames get through. This also covers
  direct messages and receipts.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
With permessage-deflate (offered by dart:io, accepted by uvicorn by
default) a real ack names an address already seen on the connection and
shrinks to about 20 bytes, while the ack of a cover frame names 56 random
characters and stays at about 75. An observer could tell them apart (QA
report 2026-11-18, T3-COVER). Uncompressed both have the same length by
design.

- The app no longer offers compression (CompressionOptions.compressionOff).
- install-relay.sh starts uvicorn with --ws-per-message-deflate false,
  because browsers always offer it. deploy/README.md describes the drop-in
  for an existing relay.
- The test relay runs with the same flag.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…e text no longer says it is impossible

- Signing out another device, or all other devices, now asks for the same
  fresh unlock (password, biometrics or security key) that guards showing the
  twelve words. Without an app lock it stays a plain confirmation. Before,
  anyone holding an unlocked second device could sign out the owner's phone
  with one tap (QA report 2026-11-18, T3-SIGNOUT).
- The restore screen still said "A device cannot be logged out" next to the
  sign-out buttons (T1-UX-005). It now explains confirming the device from the
  other one or signing out all other devices.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…and size is checked first

- The pending card read its progress under its own key, where nothing was
  ever stored; the core reports under the message id it picks. The bar stayed
  empty for the whole upload, a quarter of an hour and more for 5 GB (QA
  report 2026-11-18, T2-5GB). AppState now maps progress in the same chat
  for an id that is not an attachment there yet to the card.
- The card has a cancel button. AnhangVersand.schicke stops between chunks
  (AnhangAbgebrochen), nothing goes into the history and no error is shown.
- A file over the limit is refused before the metadata question and before
  the card appears.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…e file

A delivered queue row says who wrote to whom and when (sender, recipient,
ts). SQLite kept deleted rows as free space in their page until they happened
to be overwritten, and the WAL kept the old page image, so anyone who got the
file later could read that history back (QA report 2026-11-18).

- init_db turns on PRAGMA secure_delete, as the app does for its own
  database.
- wal_leeren() checkpoints and truncates the WAL at start and hourly in the
  janitor.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ing on desktop

Small findings from the QA report of 2026-11-18 (Linux desktop):

- The message field was single-line: line breaks could not be typed, pasted
  ones disappeared and Shift+Enter sent the message. It now grows up to six
  lines, Shift+Enter inserts a line break and Enter still sends (Android
  keeps its send key).
- Adding members beyond 20 was rejected silently; the app now says so.
- The lock screen kept the last error after a cancelled attempt, and after
  the panic password the wiped app still showed "unlock failed" on the setup
  screen. The error is cleared on a new attempt and on wipe/lock, and not set
  once the identity is gone.
- On Linux and Windows the Tor setting talked about Orbot, which only exists
  on Android.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…it confirmation

Without a factor the identity entropy lies in the system keychain and BitDM
opens without asking: anyone who can use the device, or copies the profile
folder together with the keychain, can read every message and take over the
identity. "Skip for now", "Continue", the Enter key and the back gesture all
went past this silently, while the text said a factor was needed "before the
app unlocks" (security assessment 2026-11-23, SEC-H1).

- All four ways off the secure screen now ask "Continue without protection?"
  and explain the consequence when no factor is set up.
- secureSub and the settings line "At least one factor stays required" no
  longer promise protection that does not exist (the last factor can be
  removed).
- Existing UI tests confirm the new dialog.

Making a factor mandatory is left as a separate decision.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…elay has never seen

The twelve words carry only a 4-bit BIP39 checksum, so about one in sixteen
swaps of a word for another list word passes and silently creates a
different, empty identity (security assessment 2026-11-23, SEC-H2). A
stronger checksum would break every existing phrase.

What can be said without breaking anything: an identity that was ever used
has a device at the relay. After a restore, if the relay answers 404 on the
first device query, the chat list shows a hint with "Enter the words again"
(wipes the empty identity and opens the restore screen) and "The words are
right" (identities unused for a long time or on another relay). The marker
lives in the database meta, so it survives a restart before the first
connect.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…_RUNTIME_DIR, not onto disk

A received attachment opened with another app was decrypted into the
profile folder (~/.local/share/.../anhaenge/.klar). Linux has no hook for
closing the window, so the plaintext copy stayed on disk until the next app
start (security assessment 2026-11-23, SEC-M2).

On Linux the copies now go to $XDG_RUNTIME_DIR/bitdm-klar-<hash of the
database path>: a tmpfs owned by the user (0700) that disappears at logout
and reboot. Without that variable, and on Android and Windows, the old place
stays (Android needs it for the FileProvider). Lock and wipe clean the new
folder as before, and wipe now also removes it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ot remove

Only JPEG, PNG, WebP, HEIC/AVIF and MP4/MOV are cleaned. PDF, Office/ODF
and other ZIP files, GIF, TIFF (with GPS), MP3, Matroska/WebM, Ogg, FLAC,
WAV/AVI and unknown ISO brands such as M4A went out with all metadata and
their original name, without a word (security assessment 2026-11-23,
SEC-M3).

traegtUnentfernteMetadaten() recognises these by their first bytes. Sending
one now asks the same "Send it anyway?" question as an image that could
not be cleaned, with its own text naming what goes along (author, software,
times, sometimes location, file name). The file name is kept: for a document
it is usually wanted. Voice messages are excluded as before; files without a
known signature are not asked about.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…icon

The request card showed only the first and last four characters of the
address (about 40 bits). That is exactly where the user decides whom to
accept, and a generated lookalike address could pass for a known contact
(security assessment 2026-11-23, SEC-M7).

The card now also shows the full formatted address (selectable, so it can be
compared or copied) and the identicon derived from the whole address, the
same one the chat shows after accepting.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…tore words fields

On lock the UI cleared search, PIN and password fields but kept what was
typed into the add-contact field, the remote-wipe code word field and the
twelve words on the restore screen. They stayed in the controllers (and on
screen after unlocking) as long as the app ran (security assessment
2026-11-23, SEC-M5).

_raeumeOberflaecheAuf now clears these too. The message draft is kept on
purpose, so an auto-lock after a short pause does not cost a half-written
message. Dart strings cannot be overwritten; this only drops the references.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…'s history

A trusted contact sends the remote-wipe code word as an ordinary message.
The owner's app swallows it and counts it as a wipe request, but on the
contact's side it stayed in the history in plain text, readable by anyone
holding that phone (security assessment 2026-11-23, SEC-M8).

The delivery receipt for a swallowed code word now carries the text
"tilgen". On receiving it, the contact's app blacks out that message
("••••••"), the same way it already does for the shares of the trust
backup. Older apps ignore the receipt text and acknowledge as before.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…merge conflict

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Henner4746 and others added 12 commits November 30, 2026 02:24
Version 2.1.0+24 with payment requests, the experimental Bitcoin wallet,
the fixes from the external security assessment and the Linux QA report,
and the bundled VC++ runtime for Windows.

- CHANGELOG, fastlane changelogs 24.txt (de/en), F-Droid recipe, README badges.
- Wallet intro now also says the wallet words are not behind the app lock.
- New workflow windows.yml builds the installer and zip on a GitHub runner
  on v* tags (same two-job pattern as linux.yml), so nothing is built on
  the developer PC any more.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…dialog

The tests from #41, #50 and #51 were written before #46 added the
"Continue without protection?" question, and the payment test pinned
schema 16, which #33 raised to 17 for group re-adds.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@sonarqubecloud

Copy link
Copy Markdown

Quality Gate Failed Quality Gate failed

Failed conditions
0.0% Coverage on New Code (required ≥ 80%)

See analysis details on SonarQube Cloud

@Henner4746
Henner4746 marked this pull request as ready for review November 30, 2026 02:02
@Henner4746
Henner4746 merged commit abd642d into main Nov 30, 2026
13 of 14 checks passed
@Henner4746
Henner4746 deleted the release/2.1.0 branch November 30, 2026 06:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant