@snyk/jwt-cli 0.3.1 → 0.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +7 -8
- package/bin/jwt-darwin-arm64 +0 -0
- package/bin/jwt-darwin-x64 +0 -0
- package/bin/jwt-linux-arm64 +0 -0
- package/bin/jwt-linux-x64 +0 -0
- package/bin/jwt.exe +0 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -15,7 +15,7 @@ $ npm i -g @snyk/jwt-cli
|
|
|
15
15
|
|
|
16
16
|
or the Go toolchain:
|
|
17
17
|
```shell
|
|
18
|
-
go install github.com/snyk/jwt-cli/cmd@v0.3.
|
|
18
|
+
go install github.com/snyk/jwt-cli/cmd/jwt@v0.3.1
|
|
19
19
|
```
|
|
20
20
|
|
|
21
21
|
## Create a JWT
|
|
@@ -107,13 +107,13 @@ USAGE:
|
|
|
107
107
|
jwt create [command options] [arguments...]
|
|
108
108
|
|
|
109
109
|
OPTIONS:
|
|
110
|
-
--
|
|
111
|
-
--
|
|
110
|
+
--claims value, -c value relative path to a JSON file containing claims
|
|
111
|
+
--identity_file value, -i value relative path to the identity (PEM private key) file (default: ./jwt_private_key.pem)
|
|
112
112
|
```
|
|
113
113
|
|
|
114
114
|
You can change the signing PEM with the following:
|
|
115
115
|
```shell
|
|
116
|
-
$ jwt create
|
|
116
|
+
$ jwt create -i some/other/path/private.pem
|
|
117
117
|
```
|
|
118
118
|
|
|
119
119
|
You can change the claims in the JWT by creating a claims JSON file:
|
|
@@ -129,7 +129,7 @@ You can change the claims in the JWT by creating a claims JSON file:
|
|
|
129
129
|
|
|
130
130
|
Once you have your claims in a json file, simply use the `--claims` flag to target it:
|
|
131
131
|
```shell
|
|
132
|
-
$ jwt create -
|
|
132
|
+
$ jwt create -c jwt-claims.json
|
|
133
133
|
```
|
|
134
134
|
|
|
135
135
|
### Serve
|
|
@@ -142,9 +142,8 @@ USAGE:
|
|
|
142
142
|
jwt serve [command options] [arguments...]
|
|
143
143
|
|
|
144
144
|
OPTIONS:
|
|
145
|
-
--
|
|
146
|
-
--port value,
|
|
147
|
-
|
|
145
|
+
--identity_file value, -i value relative path to the identity (PEM private key) file (default: ./jwt_private_key.pem)
|
|
146
|
+
--port value, -p value port to serve from (default: 80)
|
|
148
147
|
```
|
|
149
148
|
|
|
150
149
|
## Contributing
|
package/bin/jwt-darwin-arm64
CHANGED
|
Binary file
|
package/bin/jwt-darwin-x64
CHANGED
|
Binary file
|
package/bin/jwt-linux-arm64
CHANGED
|
Binary file
|
package/bin/jwt-linux-x64
CHANGED
|
Binary file
|
package/bin/jwt.exe
CHANGED
|
Binary file
|