<feed xmlns='http://www.w3.org/2005/Atom'>
<title>nitrokey-rs/src, branch next</title>
<subtitle>Rust interface to libnitrokey</subtitle>
<id>https://git.ireas.org/nitrokey-rs/atom?h=next</id>
<link rel='self' href='https://git.ireas.org/nitrokey-rs/atom?h=next'/>
<link rel='alternate' type='text/html' href='https://git.ireas.org/nitrokey-rs/'/>
<updated>2020-09-21T22:05:53Z</updated>
<entry>
<title>Rename *lock fields of the Config struct</title>
<updated>2020-09-21T22:05:53Z</updated>
<author>
<name>Robin Krahl</name>
<email>robin.krahl@ireas.org</email>
</author>
<published>2020-09-21T22:05:53Z</published>
<link rel='alternate' type='text/html' href='https://git.ireas.org/nitrokey-rs/commit/?id=6a94c70a2224212e2310927aec7b512d562ee455'/>
<id>urn:sha1:6a94c70a2224212e2310927aec7b512d562ee455</id>
<content type='text'>
libnitrokey calls the configuration fields that set bindings for the Num
Lock, Caps Lock and Scroll Lock keys numlock, capslock, scrolllock.  Due
to a typo, scrolllock with three l was renamed to scrollock with two l
in nitrokey-rs.

To make the field names easier to read (and type) and consistent with
the typical names for these keys, this patch changes them to num_lock,
caps_lock and scroll_lock.  In the doc comments, we now use the spelling
“Num Lock”, “Caps Lock” and “Scroll Lock”.
</content>
</entry>
<entry>
<title>Fix dead links in Device documentation</title>
<updated>2020-09-07T09:01:19Z</updated>
<author>
<name>Robin Krahl</name>
<email>robin.krahl@ireas.org</email>
</author>
<published>2020-09-07T09:01:19Z</published>
<link rel='alternate' type='text/html' href='https://git.ireas.org/nitrokey-rs/commit/?id=5df790a77a8c81b58e7507e8da5d9ac4975a64f8'/>
<id>urn:sha1:5df790a77a8c81b58e7507e8da5d9ac4975a64f8</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Fix link in User doc comment</title>
<updated>2020-09-06T11:01:36Z</updated>
<author>
<name>Robin Krahl</name>
<email>robin.krahl@ireas.org</email>
</author>
<published>2020-09-06T11:01:36Z</published>
<link rel='alternate' type='text/html' href='https://git.ireas.org/nitrokey-rs/commit/?id=3cbf6deb9d958627a8b81fdf1bd9d75d3f0ec0a3'/>
<id>urn:sha1:3cbf6deb9d958627a8b81fdf1bd9d75d3f0ec0a3</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Make *Error, Model, DeviceWrapper non-exhaustive</title>
<updated>2020-09-06T10:57:16Z</updated>
<author>
<name>Robin Krahl</name>
<email>robin.krahl@ireas.org</email>
</author>
<published>2020-09-06T10:57:16Z</published>
<link rel='alternate' type='text/html' href='https://git.ireas.org/nitrokey-rs/commit/?id=6039e0c76997014ed3f78768f8558da98d373e4b'/>
<id>urn:sha1:6039e0c76997014ed3f78768f8558da98d373e4b</id>
<content type='text'>
Previously, all enums defined by the nitrokey crate were exhaustive.
This means that adding new variants to these enums is a breaking change.
To make it possible to add new features to nitrokey-rs without breaking
compatibility, this patch marks the Error, CommandError,
CommunicationError, LibraryError, Model and DeviceWrapper enums as
non-exhaustive.
</content>
</entry>
<entry>
<title>Export the FirmwareVersion struct</title>
<updated>2020-09-05T09:59:07Z</updated>
<author>
<name>Robin Krahl</name>
<email>robin.krahl@ireas.org</email>
</author>
<published>2020-09-05T09:59:07Z</published>
<link rel='alternate' type='text/html' href='https://git.ireas.org/nitrokey-rs/commit/?id=70ea2c55d16e0a958c5694be3b4e9f086ce09844'/>
<id>urn:sha1:70ea2c55d16e0a958c5694be3b4e9f086ce09844</id>
<content type='text'>
This patch adds the FirmwareVersion struct to the re-exports in lib.rs.
Previosuly, nitrokey users where able to access FirmwareVersion values
as part of the Status struct and the Device::get_firmware_version method
but could not see its definition.
</content>
</entry>
<entry>
<title>Use map_err(|_| x) instead of or_else(|_| Err(x))</title>
<updated>2020-08-30T16:52:15Z</updated>
<author>
<name>Robin Krahl</name>
<email>robin.krahl@ireas.org</email>
</author>
<published>2020-08-30T16:52:15Z</published>
<link rel='alternate' type='text/html' href='https://git.ireas.org/nitrokey-rs/commit/?id=b2607cbd3f239be9d09204921db278424cc7a6be'/>
<id>urn:sha1:b2607cbd3f239be9d09204921db278424cc7a6be</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Remove custom source implementation for Error</title>
<updated>2020-08-30T16:43:31Z</updated>
<author>
<name>Robin Krahl</name>
<email>robin.krahl@ireas.org</email>
</author>
<published>2020-08-30T16:43:31Z</published>
<link rel='alternate' type='text/html' href='https://git.ireas.org/nitrokey-rs/commit/?id=e9a89be939acf22cf17e3d6bc505a968a98d3dee'/>
<id>urn:sha1:e9a89be939acf22cf17e3d6bc505a968a98d3dee</id>
<content type='text'>
This patch removes the custom implementation of the source method of the
std::error::Error trait for the error::Error type.  This means that the
default implementation is used that always returns None.  The reason for
this change is that we already print the error message of the source
error in the Display implementation.  This leads to a duplicated error
message if both Display and source are checked, for example with
anyhow’s error formatting.

See this thread for more information:
	https://lists.sr.ht/~ireas/nitrokey-rs-dev/%3C6e0b4dc8-9059-a113-e98e-b49e52818c75%40posteo.net%3E
</content>
</entry>
<entry>
<title>Ensure Error trait implementations</title>
<updated>2020-07-08T21:03:02Z</updated>
<author>
<name>Robin Krahl</name>
<email>robin.krahl@ireas.org</email>
</author>
<published>2020-07-08T20:58:41Z</published>
<link rel='alternate' type='text/html' href='https://git.ireas.org/nitrokey-rs/commit/?id=f1e83eb81879412e1de9898238ba58289bb6cb24'/>
<id>urn:sha1:f1e83eb81879412e1de9898238ba58289bb6cb24</id>
<content type='text'>
The anyhow crate requires that error types are error::Error, Send, Sync
and 'static.  This patch implements a simple static assertion that our
Error type implements these traits.
</content>
</entry>
<entry>
<title>Remove Error::RandError variant</title>
<updated>2020-07-08T21:02:56Z</updated>
<author>
<name>Robin Krahl</name>
<email>robin.krahl@ireas.org</email>
</author>
<published>2020-07-08T20:22:10Z</published>
<link rel='alternate' type='text/html' href='https://git.ireas.org/nitrokey-rs/commit/?id=3f402dc13530ce4de167bae843200cfbd72ed69b'/>
<id>urn:sha1:3f402dc13530ce4de167bae843200cfbd72ed69b</id>
<content type='text'>
Since we update rand_os to version 0.2 in commit
6c138eaa850c745b97b7e48a201db0cbaad8e1e0, the random number generation
can no longer fail.  Therefore the Error::RandError variant is no longer
needed.

As we did not want to break the public API, we still kept the RandError
variant.  This patch removes the RandError variant for good.
</content>
</entry>
<entry>
<title>Remove sync::PoisonError from Error::PoisonError</title>
<updated>2020-07-08T21:02:49Z</updated>
<author>
<name>Robin Krahl</name>
<email>robin.krahl@ireas.org</email>
</author>
<published>2020-07-08T10:08:26Z</published>
<link rel='alternate' type='text/html' href='https://git.ireas.org/nitrokey-rs/commit/?id=98232c7bc262dd3902b8f3e299196ab9c83fb355'/>
<id>urn:sha1:98232c7bc262dd3902b8f3e299196ab9c83fb355</id>
<content type='text'>
Previously, the Error::PoisonError contained the sync::PoisonError that
caused the error.  This is problematic as sync::PoisonError does not
implement Send, making it impossible to use the Error enum with the
anyhow crate.  At the same time, storing the sync::PoisonError is not
very useful.  If a user wants to access the poisoned lock, they can call
the force_take function.

Therefore we remove the sync::PoisonError value from the Error::
PoisonError variant.  This also allows us to simplify the
From&lt;sync::PoisonError&lt;…&gt;&gt; and From&lt;sync::TryLockError&lt;…&gt;&gt;
implementations as we no longer need to know the type of the mutex that
caused the error.

For more information, see this thread:
	https://lists.sr.ht/~ireas/nitrokey-rs-dev/%3C68ed0f3f-d98f-63bc-04d2-81b6d6cde560%40posteo.net%3E
</content>
</entry>
</feed>
