Bug 2234928 - Crashes on encryption passphrases with non-ASCII characters
Summary: Crashes on encryption passphrases with non-ASCII characters
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: libblockdev
Version: 39
Hardware: Unspecified
OS: Linux
unspecified
urgent
Target Milestone: ---
Assignee: Vojtech Trefny
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard: AcceptedBlocker
: 2234456 (view as bug list)
Depends On:
Blocks: AnacondaWebUITracker F39BetaBlocker
TreeView+ depends on / blocked
 
Reported: 2023-08-25 18:33 UTC by Adam Williamson
Modified: 2023-09-08 09:51 UTC (History)
6 users (show)

Fixed In Version: libblockdev-3.0.2-2.fc39
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2023-09-05 12:41:32 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Adam Williamson 2023-08-25 18:33:07 UTC
As discovered by vtrefny in investigating my https://bugzilla.redhat.com/show_bug.cgi?id=2234518 report, libblockdev now crashes when you set an encryption passphrase with characters outside the extended ASCII range:

https://bugzilla.redhat.com/show_bug.cgi?id=2234518#c4

Reproducible: Always

Steps to Reproduce:
    from gi.repository import BlockDev; BlockDev.init()
    BlockDev.CryptoKeyslotContext(passphrase="дддддддд")
Actual Results:  
    OverflowError: Item 0: 1076 not in range 0 to 255

Expected Results:  
it should work.

Comment 1 Adam Williamson 2023-08-25 18:34:15 UTC
Not sure how common it is for anyone to actually do this - it's a heck of a footgun, since you may well (depending on exact layout config) not be able to enter the passphrase on boot - but since it's a crash you can trigger from the installer (both old and new UI), let's propose it as a Beta FE.

Comment 2 Adam Williamson 2023-08-27 16:29:21 UTC
+3 in https://pagure.io/fedora-qa/blocker-review/issue/1200 , marking accepted.

Comment 3 Adam Williamson 2023-08-28 16:37:28 UTC
Also proposing as a Beta blocker. There's a case for this under "When using both the installer-native and the blivet-gui-based custom partitioning flow, the installer must be able to: ... Encrypt newly-created storage volumes ... Reject or disallow invalid disk and volume configurations without crashing.", I think.

Comment 4 Geoffrey Marr 2023-08-28 19:40:55 UTC
Discussed during the 2023-08-28 blocker review meeting: [0]

The decision to classify this bug as an "AcceptedBlocker (Beta)" was made as it violates the following criterion:

"When using both the installer-native and the blivet-gui-based custom partitioning flow, the installer must be able to: ... Encrypt newly-created storage volumes", in the case that you include a non-ASCII character in the passphrase (which is easy to do).

[0] https://meetbot.fedoraproject.org/fedora-blocker-review/2023-08-28/f39-blocker-review.2023-08-28-16.07.txt

Comment 5 Adam Williamson 2023-08-28 21:13:59 UTC
blocker status is greater than FE status, it doesn't need both.

Comment 6 Vojtech Trefny 2023-08-30 08:30:59 UTC
upstream PR: https://github.com/storaged-project/libblockdev/pull/954

Comment 7 Fedora Update System 2023-08-31 13:59:17 UTC
FEDORA-2023-c93a038d4d has been submitted as an update to Fedora 39. https://bodhi.fedoraproject.org/updates/FEDORA-2023-c93a038d4d

Comment 8 Adam Williamson 2023-08-31 20:47:48 UTC
Fix confirmed.

Comment 9 Fedora Update System 2023-09-01 01:46:34 UTC
FEDORA-2023-c93a038d4d has been pushed to the Fedora 39 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --refresh --advisory=FEDORA-2023-c93a038d4d`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2023-c93a038d4d

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 10 Fedora Update System 2023-09-05 12:41:32 UTC
FEDORA-2023-c93a038d4d has been pushed to the Fedora 39 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 11 Vojtech Trefny 2023-09-08 09:51:02 UTC
*** Bug 2234456 has been marked as a duplicate of this bug. ***


Note You need to log in before you can comment on or make changes to this bug.