aboutsummaryrefslogtreecommitdiff
path: root/nitrocli/Cargo.toml
Commit message (Collapse)AuthorAge
* Enable LTO and more optimizations for release buildsDaniel Mueller2018-12-29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | The program's binary is more than 1,5 MiB in size (after stripping debug symbols). Although in general that is not a size to worry about, keeping a small binary and memory footprint is beneficial in the majority of cases and leaves a tangentially better impression with users. To that end, this change enables the following optimizations to be performed when creating a release build: 1) We compile with optimization for code size. We have no performance sensitive code and are communicating with a slow I/O device to begin with, meaning that binary size will ultimately have the most weight when judging the program. Hence, minimizing it seems like the best trade-off. 2) We enable link-time optimization (LTO). At the expense of compilation time (which is not a concern for what may almost be considered a one-off operation), this step can reduce binary size by eliminating more unused code as well as enable performance related optimizations not possible without this setting. For similar reasons we disable incremental builds and treat the entire compilation as one unit. The end result of these optimizations is a reduction of binary size by almost a fourth (420 KiB). Those optimizations come at little to no cost (depending on one's view). There is another one that we could enable and that is to abort on panics instead of unwinding, yielding savings of 44 KiB. However, we refrained from doing so because that has a negative impact on the amount of error reporting happening in case of a panic.
* Bump version to 0.2.0Daniel Mueller2019-01-01
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This change bumps the version of the crate to 0.2.0. The following notable changes have been made since 0.1.3: - Use the nitrokey crate for the 'open', 'close', and 'status' commands instead of directly communicating with the Nitrokey device - Added nitrokey version 0.2.1 as a direct dependency and nitrokey-sys version 3.4.1 as well as rand version 0.4.3 as indirect dependencies - Removed the hid, hidapi-sys and pkg-config dependencies - Added the 'otp' command for working with one-time passwords - Added the 'config' command for reading and writing the device configuration - Added the 'pin' command for managing PINs - Renamed the 'clear' command to 'pin clear' - Moved 'open' and 'close' commands as subcommands into newly introduced 'storage' command - Moved printing of storage related information from 'status' command into new 'storage status' subcommand - Made 'status' command work with Nitrokey Pro devices - Enabled CI pipeline comprising code style conformance checks, linting, and building of the project - Added badges indicating pipeline status, current crates.io published version of the crate, and minimum version of rustc required - Fixed wrong messages in the pinentry dialog that were caused by unescaped spaces in a string - Use the argparse crate to parse the command-line arguments - Added argparse dependency in version 0.2.2
* Add argparse 0.2.2 as a dependencyRobin Krahl2018-12-21
| | | | | | | | | This patch adds the crate rust-argparse [0] in version 0.2.2 as a dependency, as discussed in issue #4. [0] https://github.com/tailhook/rust-argparse Import subrepo argparse/:argparse at 0de60a5e6d9ee1a3570d6089afd3ccd6ed7480c5
* Migrate work to the 'master' branchDaniel Mueller2018-12-17
| | | | | | | | | | | | In the past we have used the 'devel' branch for more or less early development work that includes the occasional rebase to fix up mistakes and keep the history clean. That is a non-starter when it comes to tagging signed releases, which we have introduced recently. Hence, there is no point in diverging from what the rest of the world is doing by using a branch name other than 'master' as the main development vehicle. By now we have introduced two dependencies on the branch name into the code base, which this change fixes up.
* Add gitlab-ci.yml configuration fileDaniel Mueller2018-12-16
| | | | | | | | | | | | | | | | | | This change adds a configuration file for the Gitlab CI/CD pipeline to the repository. This file (directly or indirectly) controls the environment in which to build, what exactly to build, and ultimately would also be used to define what tests to run. With the pipeline in place the change also adds a badge indicating the status of the build on the project's front page. The following other CI services have been evaluated or tested and found to be insufficient for the needs at hand: - Travis CI: Does not support configuration in a directory other than the repository root - Cirrus CI: Has the same problem - Semaphore: Does not support Rust - Circle CI: Does not support Rust - Google Cloud Build: Pretty much strictly a paid service
* Rename libnitrokey to nitrokeyRobin Krahl2018-12-17
| | | | | | | Currently, the nitrokey crate is renamed to libnitrokey in Cargo.toml as there used to exist a nitrokey module in this crate. As this module does no longer exist and is not likely to return, this patch removes the customized name for the nitrokey crate.
* Remove unused dependenciesRobin Krahl2018-12-17
| | | | | | | | | This patch removes all dependencies that are no longer required since the hidapi communication is replaced by libnitrokey. Delete subrepo hid/:hid Delete subrepo hidapi-sys/:hidapi-sys Delete subrepo pkg-config/:pkg-config
* Add nitrokey as a dependency to nitrocliRobin Krahl2018-12-17
| | | | | | | | | | | | | | | The nitrokey crate provides a simple interface to the Nitrokey Storage and the Nitrokey Pro based on the libnitrokey library developed by Nitrokey UG. The low-level bindings to this library are available in the nitrokey-sys crate. This patch adds version v0.2.1 of the nitrokey crate as a dependency for nitrocli. It includes the indirect dependencies nitrokey-sys (version 3.4.1) and rand (version 0.4.3). Import subrepo nitrokey/:nitrokey at 2eccc96ceec2282b868891befe9cda7f941fbe7b Import subrepo nitrokey-sys/:nitrokey-sys at f1a11ebf72610fb9cf80ac7f9f147b4ba1a5336f Import subrepo rand/:rand at d7d5da49daf7ceb3e5940072940d495cced3a1b3
* Bump version to 0.1.3Daniel Mueller2018-12-11
| | | | | | | | | | | | | | | | This change bumps the version of the crate to 0.1.3. The following notable changes have been made since 0.1.2: - Show PIN related errors through pinentry native reporting mechanism instead of emitting them to stdout - Added a man page (nitrocli(1)) for the program to the repository - Adjusted program to use Rust Edition 2018 - Applied a couple of clippy reported suggestions - Added categories to Cargo.toml - Changed dependency version requirements to be less strict (only up to the minor version and not the patch level) - Bumped pkg-config dependency to 0.3.14 - Bumped libc dependency to 0.2.45 - Bumped cc dependency to 1.0.25
* Add Cargo.toml categoriesDaniel Mueller2018-12-11
| | | | | | | | | For a while now Cargo has supported the specification of categories in the Cargo.toml file and crates.io will actually honor those categories and show case the crate in them. With this change we specify the four categories this crate is believed to fit in the best: 'command-line-utilities', 'authentication', 'cryptography', and 'hardware-support'.
* Compile program with 2018 Edition of RustDaniel Mueller2018-12-11
| | | | | | | With the 1.31 release of Rust support for Edition 2018 has reached the stable tool chain. This change enables compilation based off of this new edition for the crate. This change resolves issue #6.
* Update cc crate to 1.0.25Daniel Mueller2018-12-10
| | | | | | This change updates the cc crate to version 1.0.25. Import subrepo cc/:cc at fe0a7acb6d3e22e03bf83bcbf89367be888b5448
* Update libc crate to 0.2.45Daniel Mueller2018-12-10
| | | | | | This change updates the libc crate to version 0.2.45. Import subrepo libc/:libc at f5636fc618f8e16968b3178196d73c94ad9f7b05
* Update pkg-config crate to 0.3.14Daniel Mueller2018-12-10
| | | | | | This change updates the pkg-config crate to version 0.3.14. Import subrepo pkg-config/:pkg-config at f867f8be1babca4d6d9cddc92a817519ae845193
* Specify version requirements in a less strict mannerDaniel Mueller2018-12-10
| | | | | | | | | We try to adhere to the Semantic Versioning convention and expect dependent crates to do the same. So far we have been fairly strict in terms of the specific versions we consume, specifying the full version triple (x.y.z). This change loosens that stance by only specifying the minor version requirement of dependencies, not the patch level (i.e., x.y).
* Bump version to 0.1.2Daniel Mueller2018-01-15
|
* Update hidapi-sys crate to 0.1.4Daniel Mueller2018-01-15
| | | | | | | | | This change updates the hidapi-sys crate to version 0.1.4. In this version the cc crate (the stable and renamed version of the gcc crate) is used. Import subrepo hidapi-sys/:hidapi-sys at c01043da72c0cac898660017e4c4115278c14369 Import subrepo cc/:cc at 500c65b03775cecf55bd358e616963bc3222acca
* Update libc crate to 0.2.36Daniel Mueller2018-01-15
| | | | Import subrepo libc/:libc at 16a0f4a3d6c836f88f50c58f5d0a74a32cbf0193
* Update hid crate to 0.4.1Daniel Mueller2017-11-10
| | | | Import subrepo hid/:hid at 6dc63c8682bd2f027c0d3b4a004b097ca9ac49fa
* Update libc crate to 0.2.30Daniel Mueller2017-09-16
| | | | Import subrepo libc/:libc at 3520512a8c9cb55661910318a6fb169a75c02a59
* Update gcc crate to 0.3.54Daniel Mueller2017-09-16
| | | | Import subrepo gcc/:gcc at dc329205d54b53a45ab66368aed265b68fe7f261
* Bump version to 0.1.1Daniel Mueller2017-08-17
|
* Explicitly mention versions for local dependenciesDaniel Mueller2017-05-29
| | | | | | | | Although the version information for all the local dependencies can be inferred from various locations, cargo requires an explicit mentioning of the version of each dependency for the 'package' command to be successful. This change adds explicit versions.
* Update libc crate to 0.2.23Daniel Mueller2017-05-29
| | | | | | | The 'libc' create got a couple of updates. This change imports the new code and bumps the version to use. Import subrepo libc/:libc at 7db3fd570dfb41a38fb17116e93679307178103a
* Update gcc crate to 0.3.48Daniel Mueller2017-05-29
| | | | | | | The 'gcc' create got a couple of updates. This change imports the new code and bumps the version to use. Import subrepo gcc/:gcc at 6b41873be3172415efcadbff1187a3ff42428943
* Update hid crate to version 0.4.0Daniel Mueller2017-03-27
| | | | | | | | The 'hid' crate got a couple of bug fixes, at least one of which we require in order to retrieve HID feature reports correctly. This patch imports the new state and bumps up the library version used. Import subrepo hid/:hid at 52b47d78c17b876194e4b4a1c0c8ae8adfb3d39c
* Discover and open nictrokey using libhidapiDaniel Mueller2017-03-26
| | | | | | | | | | | This change uses the 'hid' crate to discover and open the Nitrokey Storage device. 'hid' is a wrapper around libhidapi (its libusb back-end in particular). Being a command line application some sort of parameter handling needs to happen. The approach we take is very simple for now to minimize the number of dependencies: we just compare the first argument against the expected ones and raise an error if no match was found. Because we only have positional arguments right now this is all we need.
* Add basic scaffoldingDaniel Mueller2017-03-03
This change adds the basic scaffolding for the nitrocli application. The scaffolding was created using the following command: $ cargo new --bin nitrocli The application aims at providing a command line interface for the Nitrokey Storage device.