Skip to content

Commit

Permalink
Merge pull request #2895 from timeplus-io/feature/nkey-for-nats
Browse files Browse the repository at this point in the history
feat: added nkey field to nats
  • Loading branch information
mihaitodor authored Oct 9, 2024
2 parents f1786c5 + 6e5ce52 commit 5b829dc
Show file tree
Hide file tree
Showing 12 changed files with 272 additions and 12 deletions.
22 changes: 21 additions & 1 deletion docs/modules/components/pages/caches/nats_kv.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ nats_kv:
client_certs: []
auth:
nkey_file: ./seed.nk # No default (optional)
nkey: '!!!SECRET_SCRUBBED!!!' # No default (optional)
user_credentials_file: ./user.creds # No default (optional)
user_jwt: "" # No default (optional)
user_nkey_seed: "" # No default (optional)
Expand Down Expand Up @@ -92,7 +93,7 @@ See an https://docs.nats.io/running-a-nats-service/nats_admin/security/jwt[in-de
The NATS server can use these NKeys in several ways for authentication. The simplest is for the server to be configured
with a list of known public keys and for the clients to respond to the challenge by signing it with its private NKey
configured in the `nkey_file` field.
configured in the `nkey_file` or `nkey` field.
https://docs.nats.io/running-a-nats-service/configuration/securing_nats/auth_intro/nkey_auth[More details^].
Expand Down Expand Up @@ -326,6 +327,25 @@ An optional file containing a NKey seed.
nkey_file: ./seed.nk
```
=== `auth.nkey`
The NKey seed.
[CAUTION]
====
This field contains sensitive information that usually shouldn't be added to a config directly, read our xref:configuration:secrets.adoc[secrets page for more info].
====
*Type*: `string`
```yml
# Examples
nkey: UDXU4RCSJNZOIQHZNWXHXORDPRTGNJAHAHFRGZNEEJCPQTT2M7NLCNF4
```
=== `auth.user_credentials_file`
An optional file containing user credentials which consist of an user JWT and corresponding NKey seed.
Expand Down
22 changes: 21 additions & 1 deletion docs/modules/components/pages/inputs/nats.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ input:
client_certs: []
auth:
nkey_file: ./seed.nk # No default (optional)
nkey: '!!!SECRET_SCRUBBED!!!' # No default (optional)
user_credentials_file: ./user.creds # No default (optional)
user_jwt: "" # No default (optional)
user_nkey_seed: "" # No default (optional)
Expand Down Expand Up @@ -113,7 +114,7 @@ See an https://docs.nats.io/running-a-nats-service/nats_admin/security/jwt[in-de
The NATS server can use these NKeys in several ways for authentication. The simplest is for the server to be configured
with a list of known public keys and for the clients to respond to the challenge by signing it with its private NKey
configured in the `nkey_file` field.
configured in the `nkey_file` or `nkey` field.
https://docs.nats.io/running-a-nats-service/configuration/securing_nats/auth_intro/nkey_auth[More details^].
Expand Down Expand Up @@ -402,6 +403,25 @@ An optional file containing a NKey seed.
nkey_file: ./seed.nk
```
=== `auth.nkey`
The NKey seed.
[CAUTION]
====
This field contains sensitive information that usually shouldn't be added to a config directly, read our xref:configuration:secrets.adoc[secrets page for more info].
====
*Type*: `string`
```yml
# Examples
nkey: UDXU4RCSJNZOIQHZNWXHXORDPRTGNJAHAHFRGZNEEJCPQTT2M7NLCNF4
```
=== `auth.user_credentials_file`
An optional file containing user credentials which consist of an user JWT and corresponding NKey seed.
Expand Down
22 changes: 21 additions & 1 deletion docs/modules/components/pages/inputs/nats_jetstream.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,7 @@ input:
client_certs: []
auth:
nkey_file: ./seed.nk # No default (optional)
nkey: '!!!SECRET_SCRUBBED!!!' # No default (optional)
user_credentials_file: ./user.creds # No default (optional)
user_jwt: "" # No default (optional)
user_nkey_seed: "" # No default (optional)
Expand Down Expand Up @@ -128,7 +129,7 @@ See an https://docs.nats.io/running-a-nats-service/nats_admin/security/jwt[in-de
The NATS server can use these NKeys in several ways for authentication. The simplest is for the server to be configured
with a list of known public keys and for the clients to respond to the challenge by signing it with its private NKey
configured in the `nkey_file` field.
configured in the `nkey_file` or `nkey` field.
https://docs.nats.io/running-a-nats-service/configuration/securing_nats/auth_intro/nkey_auth[More details^].
Expand Down Expand Up @@ -449,6 +450,25 @@ An optional file containing a NKey seed.
nkey_file: ./seed.nk
```
=== `auth.nkey`
The NKey seed.
[CAUTION]
====
This field contains sensitive information that usually shouldn't be added to a config directly, read our xref:configuration:secrets.adoc[secrets page for more info].
====
*Type*: `string`
```yml
# Examples
nkey: UDXU4RCSJNZOIQHZNWXHXORDPRTGNJAHAHFRGZNEEJCPQTT2M7NLCNF4
```
=== `auth.user_credentials_file`
An optional file containing user credentials which consist of an user JWT and corresponding NKey seed.
Expand Down
22 changes: 21 additions & 1 deletion docs/modules/components/pages/inputs/nats_kv.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,7 @@ input:
client_certs: []
auth:
nkey_file: ./seed.nk # No default (optional)
nkey: '!!!SECRET_SCRUBBED!!!' # No default (optional)
user_credentials_file: ./user.creds # No default (optional)
user_jwt: "" # No default (optional)
user_nkey_seed: "" # No default (optional)
Expand Down Expand Up @@ -114,7 +115,7 @@ See an https://docs.nats.io/running-a-nats-service/nats_admin/security/jwt[in-de
The NATS server can use these NKeys in several ways for authentication. The simplest is for the server to be configured
with a list of known public keys and for the clients to respond to the challenge by signing it with its private NKey
configured in the `nkey_file` field.
configured in the `nkey_file` or `nkey` field.
https://docs.nats.io/running-a-nats-service/configuration/securing_nats/auth_intro/nkey_auth[More details^].
Expand Down Expand Up @@ -405,6 +406,25 @@ An optional file containing a NKey seed.
nkey_file: ./seed.nk
```
=== `auth.nkey`
The NKey seed.
[CAUTION]
====
This field contains sensitive information that usually shouldn't be added to a config directly, read our xref:configuration:secrets.adoc[secrets page for more info].
====
*Type*: `string`
```yml
# Examples
nkey: UDXU4RCSJNZOIQHZNWXHXORDPRTGNJAHAHFRGZNEEJCPQTT2M7NLCNF4
```
=== `auth.user_credentials_file`
An optional file containing user credentials which consist of an user JWT and corresponding NKey seed.
Expand Down
22 changes: 21 additions & 1 deletion docs/modules/components/pages/inputs/nats_stream.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@ input:
client_certs: []
auth:
nkey_file: ./seed.nk # No default (optional)
nkey: '!!!SECRET_SCRUBBED!!!' # No default (optional)
user_credentials_file: ./user.creds # No default (optional)
user_jwt: "" # No default (optional)
user_nkey_seed: "" # No default (optional)
Expand Down Expand Up @@ -117,7 +118,7 @@ See an https://docs.nats.io/running-a-nats-service/nats_admin/security/jwt[in-de
The NATS server can use these NKeys in several ways for authentication. The simplest is for the server to be configured
with a list of known public keys and for the clients to respond to the challenge by signing it with its private NKey
configured in the `nkey_file` field.
configured in the `nkey_file` or `nkey` field.
https://docs.nats.io/running-a-nats-service/configuration/securing_nats/auth_intro/nkey_auth[More details^].
Expand Down Expand Up @@ -417,6 +418,25 @@ An optional file containing a NKey seed.
nkey_file: ./seed.nk
```
=== `auth.nkey`
The NKey seed.
[CAUTION]
====
This field contains sensitive information that usually shouldn't be added to a config directly, read our xref:configuration:secrets.adoc[secrets page for more info].
====
*Type*: `string`
```yml
# Examples
nkey: UDXU4RCSJNZOIQHZNWXHXORDPRTGNJAHAHFRGZNEEJCPQTT2M7NLCNF4
```
=== `auth.user_credentials_file`
An optional file containing user credentials which consist of an user JWT and corresponding NKey seed.
Expand Down
22 changes: 21 additions & 1 deletion docs/modules/components/pages/outputs/nats.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@ output:
client_certs: []
auth:
nkey_file: ./seed.nk # No default (optional)
nkey: '!!!SECRET_SCRUBBED!!!' # No default (optional)
user_credentials_file: ./user.creds # No default (optional)
user_jwt: "" # No default (optional)
user_nkey_seed: "" # No default (optional)
Expand Down Expand Up @@ -105,7 +106,7 @@ See an https://docs.nats.io/running-a-nats-service/nats_admin/security/jwt[in-de
The NATS server can use these NKeys in several ways for authentication. The simplest is for the server to be configured
with a list of known public keys and for the clients to respond to the challenge by signing it with its private NKey
configured in the `nkey_file` field.
configured in the `nkey_file` or `nkey` field.
https://docs.nats.io/running-a-nats-service/configuration/securing_nats/auth_intro/nkey_auth[More details^].
Expand Down Expand Up @@ -417,6 +418,25 @@ An optional file containing a NKey seed.
nkey_file: ./seed.nk
```
=== `auth.nkey`
The NKey seed.
[CAUTION]
====
This field contains sensitive information that usually shouldn't be added to a config directly, read our xref:configuration:secrets.adoc[secrets page for more info].
====
*Type*: `string`
```yml
# Examples
nkey: UDXU4RCSJNZOIQHZNWXHXORDPRTGNJAHAHFRGZNEEJCPQTT2M7NLCNF4
```
=== `auth.user_credentials_file`
An optional file containing user credentials which consist of an user JWT and corresponding NKey seed.
Expand Down
22 changes: 21 additions & 1 deletion docs/modules/components/pages/outputs/nats_jetstream.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,7 @@ output:
client_certs: []
auth:
nkey_file: ./seed.nk # No default (optional)
nkey: '!!!SECRET_SCRUBBED!!!' # No default (optional)
user_credentials_file: ./user.creds # No default (optional)
user_jwt: "" # No default (optional)
user_nkey_seed: "" # No default (optional)
Expand Down Expand Up @@ -105,7 +106,7 @@ See an https://docs.nats.io/running-a-nats-service/nats_admin/security/jwt[in-de
The NATS server can use these NKeys in several ways for authentication. The simplest is for the server to be configured
with a list of known public keys and for the clients to respond to the challenge by signing it with its private NKey
configured in the `nkey_file` field.
configured in the `nkey_file` or `nkey` field.
https://docs.nats.io/running-a-nats-service/configuration/securing_nats/auth_intro/nkey_auth[More details^].
Expand Down Expand Up @@ -422,6 +423,25 @@ An optional file containing a NKey seed.
nkey_file: ./seed.nk
```
=== `auth.nkey`
The NKey seed.
[CAUTION]
====
This field contains sensitive information that usually shouldn't be added to a config directly, read our xref:configuration:secrets.adoc[secrets page for more info].
====
*Type*: `string`
```yml
# Examples
nkey: UDXU4RCSJNZOIQHZNWXHXORDPRTGNJAHAHFRGZNEEJCPQTT2M7NLCNF4
```
=== `auth.user_credentials_file`
An optional file containing user credentials which consist of an user JWT and corresponding NKey seed.
Expand Down
22 changes: 21 additions & 1 deletion docs/modules/components/pages/outputs/nats_kv.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ output:
client_certs: []
auth:
nkey_file: ./seed.nk # No default (optional)
nkey: '!!!SECRET_SCRUBBED!!!' # No default (optional)
user_credentials_file: ./user.creds # No default (optional)
user_jwt: "" # No default (optional)
user_nkey_seed: "" # No default (optional)
Expand Down Expand Up @@ -102,7 +103,7 @@ See an https://docs.nats.io/running-a-nats-service/nats_admin/security/jwt[in-de
The NATS server can use these NKeys in several ways for authentication. The simplest is for the server to be configured
with a list of known public keys and for the clients to respond to the challenge by signing it with its private NKey
configured in the `nkey_file` field.
configured in the `nkey_file` or `nkey` field.
https://docs.nats.io/running-a-nats-service/configuration/securing_nats/auth_intro/nkey_auth[More details^].
Expand Down Expand Up @@ -364,6 +365,25 @@ An optional file containing a NKey seed.
nkey_file: ./seed.nk
```
=== `auth.nkey`
The NKey seed.
[CAUTION]
====
This field contains sensitive information that usually shouldn't be added to a config directly, read our xref:configuration:secrets.adoc[secrets page for more info].
====
*Type*: `string`
```yml
# Examples
nkey: UDXU4RCSJNZOIQHZNWXHXORDPRTGNJAHAHFRGZNEEJCPQTT2M7NLCNF4
```
=== `auth.user_credentials_file`
An optional file containing user credentials which consist of an user JWT and corresponding NKey seed.
Expand Down
22 changes: 21 additions & 1 deletion docs/modules/components/pages/outputs/nats_stream.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ output:
client_certs: []
auth:
nkey_file: ./seed.nk # No default (optional)
nkey: '!!!SECRET_SCRUBBED!!!' # No default (optional)
user_credentials_file: ./user.creds # No default (optional)
user_jwt: "" # No default (optional)
user_nkey_seed: "" # No default (optional)
Expand Down Expand Up @@ -97,7 +98,7 @@ See an https://docs.nats.io/running-a-nats-service/nats_admin/security/jwt[in-de
The NATS server can use these NKeys in several ways for authentication. The simplest is for the server to be configured
with a list of known public keys and for the clients to respond to the challenge by signing it with its private NKey
configured in the `nkey_file` field.
configured in the `nkey_file` or `nkey` field.
https://docs.nats.io/running-a-nats-service/configuration/securing_nats/auth_intro/nkey_auth[More details^].
Expand Down Expand Up @@ -355,6 +356,25 @@ An optional file containing a NKey seed.
nkey_file: ./seed.nk
```
=== `auth.nkey`
The NKey seed.
[CAUTION]
====
This field contains sensitive information that usually shouldn't be added to a config directly, read our xref:configuration:secrets.adoc[secrets page for more info].
====
*Type*: `string`
```yml
# Examples
nkey: UDXU4RCSJNZOIQHZNWXHXORDPRTGNJAHAHFRGZNEEJCPQTT2M7NLCNF4
```
=== `auth.user_credentials_file`
An optional file containing user credentials which consist of an user JWT and corresponding NKey seed.
Expand Down
Loading

0 comments on commit 5b829dc

Please sign in to comment.