Add support for U2F authentication#3638
Merged
svartkanin merged 6 commits intoarchlinux:masterfrom Jun 30, 2025
Merged
Conversation
Torxed
approved these changes
Jun 29, 2025
Member
Torxed
left a comment
There was a problem hiding this comment.
Awesome addition! Just a small pylint thing then we can merge!
codefiles
reviewed
Jun 30, 2025
| parent_dev_path = device_handler.get_parent_device_path(boot_partition.safe_dev_path) | ||
|
|
||
| cmd_template = ( | ||
| cmd_template = [ |
Contributor
There was a problem hiding this comment.
Why was this changed? What did this have to do with this pull request?
This was a tuple because it avoids unnecessary mutability, has the slight benefit of using less memory, and communicates that it is a static sequence meant to be reused. It is being formatted and expanded into lists later anyway.
Collaborator
Author
There was a problem hiding this comment.
Thanks for pointing this out, it was accidentally committed, reverted #3648
Contributor
|
With the changes in the last commit, this should have been reviewed and approved again before merging. |
Traceback (most recent call last):
File "/home/celestifyx/Desktop/archinstall/archinstall/__init__.py", line 104, in run_as_a_module
rc = main()
File "/home/celestifyx/Desktop/archinstall/archinstall/__init__.py", line 94, in main
importlib.import_module(mod_name)
~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^
File "/usr/lib/python3.13/importlib/__init__.py", line 88, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "<frozen importlib._bootstrap>", line 1387, in _gcd_import
File "<frozen importlib._bootstrap>", line 1360, in _find_and_load
File "<frozen importlib._bootstrap>", line 1331, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 935, in _load_unlocked
File "<frozen importlib._bootstrap_external>", line 1026, in exec_module
File "<frozen importlib._bootstrap>", line 488, in _call_with_frames_removed
File "/home/celestifyx/Desktop/archinstall/archinstall/scripts/guided.py", line 212, in <module>
guided()
~~~~~~^^
File "/home/celestifyx/Desktop/archinstall/archinstall/scripts/guided.py", line 186, in guided
ask_user_questions()
~~~~~~~~~~~~~~~~~~^^
File "/home/celestifyx/Desktop/archinstall/archinstall/scripts/guided.py", line 47, in ask_user_questions
global_menu.run(additional_title=title_text)
~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/celestifyx/Desktop/archinstall/archinstall/lib/menu/abstract_menu.py", line 113, in run
).run()
~~~^^
File "/home/celestifyx/Desktop/archinstall/archinstall/tui/curses_menu.py", line 757, in run
result = Tui.run(self)
File "/home/celestifyx/Desktop/archinstall/archinstall/tui/curses_menu.py", line 1349, in run
return Tui.t()._main_loop(component)
~~~~~~~~~~~~~~~~~~^^^^^^^^^^^
File "/home/celestifyx/Desktop/archinstall/archinstall/tui/curses_menu.py", line 1357, in _main_loop
return component.kickoff(self._screen)
~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^
File "/home/celestifyx/Desktop/archinstall/archinstall/tui/curses_menu.py", line 772, in kickoff
ret = self._process_input_key(key)
File "/home/celestifyx/Desktop/archinstall/archinstall/tui/curses_menu.py", line 1187, in _process_input_key
item.value = item.action(item.value)
~~~~~~~~~~~^^^^^^^^^^^^
File "/home/celestifyx/Desktop/archinstall/archinstall/lib/global_menu.py", line 270, in _select_authentication
auth_config = AuthenticationMenu(preset).run()
~~~~~~~~~~~~~~~~~~^^^^^^^^
File "/home/celestifyx/Desktop/archinstall/archinstall/lib/authentication/authentication_menu.py", line 21, in __init__
self._item_group = MenuItemGroup(menu_optioons, checkmarks=True)
~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/celestifyx/Desktop/archinstall/archinstall/tui/menu_item.py", line 97, in __init__
self.focus_first()
~~~~~~~~~~~~~~~~^^
File "/home/celestifyx/Desktop/archinstall/archinstall/tui/menu_item.py", line 278, in focus_first
if first_item and not self._is_selectable(first_item):
~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^
File "/home/celestifyx/Desktop/archinstall/archinstall/tui/menu_item.py", line 349, in _is_selectable
return self.is_enabled(item)
~~~~~~~~~~~~~~~^^^^^^
File "/home/celestifyx/Desktop/archinstall/archinstall/tui/menu_item.py", line 361, in is_enabled
return dep()
File "/home/celestifyx/Desktop/archinstall/archinstall/lib/authentication/authentication_menu.py", line 47, in _depends_on_u2f
devices = Fido2.get_fido2_devices()
File "/home/celestifyx/Desktop/archinstall/archinstall/lib/disk/fido.py", line 40, in get_fido2_devices
path, details = line.replace(',', '').split(':', maxsplit=1)
^^^^^^^^^^^^^
ValueError: not enough values to unpack (expected 2, got 1)@svartkanin fix |
Collaborator
Author
|
@CelestifyX could you share your log |
Collaborator
Author
|
@CelestifyX this should fix it #3648 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR adds support for U2F device login #1286.
Authenticationmenu entryU2F login setupentry is only displayed IF a U2F device was found/etc/pam.d/system-loginand optionally the/etc/pam.d/sudofileskde,sddm,gdm-passwordand thereby applyFuture PR
Root passwordandUser accountsinto theAuthenticationmenu