altinn-jwks
1.1.0
dotnet tool install --global altinn-jwks --version 1.1.0
dotnet new tool-manifest # if you are setting up this repo dotnet tool install --local altinn-jwks --version 1.1.0
#tool dotnet:?package=altinn-jwks&version=1.1.0
nuke :add-package altinn-jwks --version 1.1.0
Altinn.Cli Console App
The Altinn.JwkGenerator
console application provides a convenient way to generate Json Web Keys.
Installation
Install using dotnet tool install -g altinn-jwks
.
Usage
Use your favorite terminal and execute the altinn-jwks
.
Here's an example of the altinn-jwks
console application's built in help page:
Description:
Creates a new JWK
Usage:
altinn-jwks create <name> [options]
Arguments:
<name> Name of the integration to generate JWKs for.
Options:
-d, -t, --dev, --test Generate TEST keys. Defaults to true unless --prod is specified.
-p, --prod Generate PROD keys. Defaults to true unless --test is specified.
-s, --size <size> Key size in bits.
-a, --alg, --algorithm <ES256|ES384|ES512|RS256|RS384|RS512> The algorithm to use for the key. [default: RS256]
-u, --use <enc|sig> Use for the JWK. [default: sig]
-o, --out <DIR> Output directory for the generated JWKs. [default: $PATH]
-?, -h, --help Show help and usage information
Create command
To create a JWK using the default values simply execute the app with the create
command:
.\altinn-jwks create br
Output:
Generating key br-TEST.2024-06-21 for key-set br-TEST
Generating key br-PROD.2024-06-21 for key-set br-PROD
Any of the options
can be used to override defaults when executing thecreate
command:
.\altinn-jwks create br --size 4096 --alg RS512 --use sig --out ./keys
Output:
Generating key br-TEST.2024-06-21 for key-set br-TEST
Generating key br-PROD.2024-06-21 for key-set br-PROD
Contributing
Contributions are welcome! If you find any issues or have suggestions for improvements, please feel free to open an issue or submit a pull request on GitHub.
License
This library is licensed under the MIT License.
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net8.0 is compatible. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. |
This package has no dependencies.
# Changelog
## [1.1.0](https://github.com/Altinn/altinn-authorization-utils/compare/Altinn.Cli-v1.0.0...Altinn.Cli-v1.1.0) (2024-07-25)
### Features
* add keyvault as valid jwks store ([58346b7](https://github.com/Altinn/altinn-authorization-utils/commit/58346b739fc1a7ffaea72bfeb825e9b794827f9e))
## 1.0.0 (2024-06-28)
### Features
* Create altinn-jwks Console App ([#72](https://github.com/Altinn/altinn-authorization-utils/issues/72)) ([b5d1dc0](https://github.com/Altinn/altinn-authorization-utils/commit/b5d1dc0cc55eedc1c6ff3fe97f6cd76ec9704b56))