-
Notifications
You must be signed in to change notification settings - Fork 26
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Upstream merge #46
Upstream merge #46
Conversation
pub const MESSAGE_SIZE: usize = PACKET_SIZE - 7 + 128 * (PACKET_SIZE - 5); | ||
// 1200 | ||
// pub const MESSAGE_SIZE: usize = ctap_types::sizes::REALISTIC_MAX_MESSAGE_SIZE; | ||
pub const MESSAGE_SIZE: usize = 3072; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This one looks arbitrary. To confirm its origin.
runners/lpc55/.cargo/config.toml
Outdated
# "-Dwarnings", | ||
"-Dwarnings", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What's this one doing? -D
is of course defining a macro, but what's its purpose?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
-D, --deny LINT Set lint denied
– so this should make the compilation fail if there are compiler warnings. Makes sense for the CI, less so for development.
runners/lpc55/src/initializer.rs
Outdated
fn get_serial_number() -> &'static str { | ||
/*static mut SERIAL_NUMBER: heapless::String<heapless::consts::U36> = heapless::String(heapless::i::String::new()); | ||
use core::fmt::Write; | ||
unsafe { | ||
let uuid = crate::hal::uuid(); | ||
SERIAL_NUMBER.write_fmt(format_args!("{}", hexstr!(&uuid))).unwrap(); | ||
&SERIAL_NUMBER | ||
}*/ | ||
"00000000-0000-0000-00000000" | ||
} | ||
|
||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
IMO showing serial number should be configurable, with the default being the SN exposed to allow managing devices in the enterprise setting. Let's discuss this.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We had this discussion before the release and the conclusion was that we disable it by default and add an option to enable it later.
// let remaining = msp() - 0x2000_0000; | ||
// if remaining < 100_000 { | ||
// debug_now!("USB interrupt: remaining stack size: {} bytes", remaining); | ||
// } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This debug code should be active in the develop
builds, or removed completely.
Similarly other statements like that.
AFAIK
Yes, we do. See spec below. Let's make sure the proper version is used.
Yes, math lib for that looks like overkill to me as well. Why the final values were not tabularized / calculated during the build via the const func? Do you know what was wrong with the initial
AFAIK it got removed in the upstream, as this was mainly debug feature. Or am I wrong? |
Final question: have you used the stable upstream release for the merge? Or an arbitrary commit? |
re. RGB: We want to change the LED patterns anyway and remove the pulsing. Maybe just change it to constant colors in this PR and then change it to the colors we actually want before the next release? |
Bumping. ETA? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not tested yet, just based on the code change:
- I’d also like some more context for the constant changes regarding CTAPHID packet size, as mentioned by Szczepan
- I think we should change the LED code to keep the status quo for the moment – this should also remove the need for the math dependency.
- Instead of setting an all-zero serial number, can’t we just remove the
.serial_number(serial_number)
call?
Is this fixing below by any chance? |
That should already be fixed with our v1.0.1 release. The issue we are having with resident keys is querying them, not creating them. Edit: I replied to an old version of your comment. The download issue is not fixed yet AFAIK, but I haven’t tested it yet with the current fido-authenticator. |
This patch removes solo2-specific targets from the Makefile.
This patch indicates the LED pulsing. This does not change the current behavior for production devices as LED pulsing is not working due to a missing peripheral in locked mode in the current firmware version.
Instead of setting an all-zero serial number for the USB device, we remove the serial number entirely to maintain the status quo.
This patch removes the -Dwarnings flag from the cargo configuration that fails the build if there is a warning. While this setting makes sense in the CI, it is annoying during development.
Due to recent changes in Trussed, the LED is blinking during a user confirmation request if it is processing data, for example on webauthn.bin.coffee. This patch restores the old behavior by using a custom Trussed version that does not change the LED when processing data and by fixing the refresh method in board/src/trussed.rs.
I’ve added some commits to finalize this PR – in my opinion, it is ready now. @szszszsz @daringer Please review. The only non-trivial change I made is the last commit. It is necessary to maintain the current LED behavior, but it has to use a patched Trussed version because of the upstream changes. Here is the required patch. |
Also, can someone please test NFC with these changes as there seem to be new issues for solo2? |
@daringer Engage! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
+1
To test:
|
Looks good. I do not see any problems while using under the latest Windows 10. #48 is fixed.
|
merge notes/todos:
dispatch-fido
is not needed anymore, thus remove (included infido-auth
with "dispatch" in features)fido-authenticator
has been taken fromupstream/main
for now -> @todo ?fido-authenticator
upstream, or stay on version = 0.1ctaphid.set_version(usbd_ctaphid::Version {
initilizer.rs
initializer.rs
get_serial_number()
board/trussed.rs
Intensities::scale_by()
for easy scaling (currently misused by scaling with the amplitude...)src/types.rs
UsbClasses
with or withoutserial
?#cfg[]
? based on feature?serial
pulled in for now...