Add NFC support for set_mode.

This commit is contained in:
Dain Nilsson 2022-05-06 08:34:16 +02:00
parent 338d8773c3
commit 977f509982
No known key found for this signature in database
GPG Key ID: F04367096FBA95E8
4 changed files with 11 additions and 6 deletions

View File

@ -77,6 +77,7 @@ class _DesktopManagementStateNotifier extends ManagementStateNotifier {
'challenge_response_timeout': challengeResponseTimeout,
'auto_eject_timeout': autoEjectTimeout,
});
_ref.read(attachedDevicesProvider.notifier).refresh();
}
@override

View File

@ -204,7 +204,12 @@ class _ManagementScreenState extends ConsumerState<ManagementScreen> {
.read(managementStateProvider(widget.deviceData.node.path).notifier)
.setMode(interfaces: _interfaces);
showMessage(
context, 'Configuration updated, remove and reinsert your YubiKey');
context,
widget.deviceData.node.maybeMap(
nfcReader: (_) => 'Configuration updated',
orElse: () =>
'Configuration updated, remove and reinsert your YubiKey'));
Navigator.pop(context);
}
void _submitForm() {

7
ykman-rpc/poetry.lock generated
View File

@ -369,8 +369,8 @@ pywin32 = {version = ">=223", markers = "sys_platform == \"win32\""}
[package.source]
type = "git"
url = "https://github.com/Yubico/yubikey-manager.git"
reference = "e37f5f8"
resolved_reference = "e37f5f87140795e32f38933a99140f4b07ccd6c2"
reference = "next"
resolved_reference = "61b902b5f61024b27f32ef88b2f95bb7630afdfb"
[[package]]
name = "zipp"
@ -398,7 +398,7 @@ numpy = "*"
[metadata]
lock-version = "1.1"
python-versions = "^3.8"
content-hash = "d9b4682af5b547e5e0bc2d2efcd6ccbb1c76115fbfdb654b8786d380a5821b77"
content-hash = "04aaecbad4bcfea25ea9070c13eec47f06a2f8d7155d1a96c9dafac7780c8805"
[metadata.files]
altgraph = [
@ -533,7 +533,6 @@ numpy = [
{file = "numpy-1.22.3-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:8251ed96f38b47b4295b1ae51631de7ffa8260b5b087808ef09a39a9d66c97ab"},
{file = "numpy-1.22.3-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:48a3aecd3b997bf452a2dedb11f4e79bc5bfd21a1d4cc760e703c31d57c84b3e"},
{file = "numpy-1.22.3-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a3bae1a2ed00e90b3ba5f7bd0a7c7999b55d609e0c54ceb2b076a25e345fa9f4"},
{file = "numpy-1.22.3-cp310-cp310-win32.whl", hash = "sha256:f950f8845b480cffe522913d35567e29dd381b0dc7e4ce6a4a9f9156417d2430"},
{file = "numpy-1.22.3-cp310-cp310-win_amd64.whl", hash = "sha256:08d9b008d0156c70dc392bb3ab3abb6e7a711383c3247b410b39962263576cd4"},
{file = "numpy-1.22.3-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:201b4d0552831f7250a08d3b38de0d989d6f6e4658b709a02a73c524ccc6ffce"},
{file = "numpy-1.22.3-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:f8c1f39caad2c896bc0018f699882b345b2a63708008be29b1f355ebf6f933fe"},

View File

@ -6,7 +6,7 @@ authors = ["Dain Nilsson <dain@yubico.com>"]
[tool.poetry.dependencies]
python = "^3.8"
yubikey-manager = { git = "https://github.com/Yubico/yubikey-manager.git", rev = "e37f5f8" }
yubikey-manager = { git = "https://github.com/Yubico/yubikey-manager.git", branch = "next" }
fido2 = {version = "1.0.0rc1", allow-prereleases = true}
mss = "^6.1.0"
zxing-cpp = "^1.2.0"