Commit Graph

100 Commits

Author SHA1 Message Date
Derek Collison
37cf7584bd Merge branch 'master' into jsc 2021-01-14 02:52:35 -07:00
Derek Collison
f0cdf89c61 JetStream Clustering WIP
Signed-off-by: Derek Collison <derek@nats.io>
2021-01-14 01:14:52 -08:00
Matthias Hanel
0ff6252692 Added tests for cfg/jwt based queue restrictions and updated jwt lib
Signed-off-by: Matthias Hanel <mh@synadia.com>
2021-01-07 17:30:51 -05:00
Matthias Hanel
d59b074c64 Incorporating review comments
Signed-off-by: Matthias Hanel <mh@synadia.com>
2021-01-05 18:45:46 -05:00
Matthias Hanel
592a6447a7 [Added] support for wildcard services and import remapping by JWT.
Imports in JWT where extended to contain a new filed LocalSubject.
This Change pulls the new JWT library version in.
It was needed as prefix did not exist in the JWT library and the
original field could not be used. The field To has been deprecated.

When LocalSubject is set, service imports can be configured the same way
they are in config. Meaning, no reversal due to the type.

This change also ensures that wildcard references in transforms are only
set in To/LocalSubject. Before, for services, $1 would have to be set in Subject.

Signed-off-by: Matthias Hanel <mh@synadia.com>
2021-01-04 14:11:36 -05:00
Alberto Ricart
f09992a889 updated iteration of signing keys (previously a list, now a map). (#1779) 2020-12-17 13:59:18 -07:00
Matthias Hanel
c6daffbfcc [Added] ability to use jwt latency sampling properties headers/share
Signed-off-by: Matthias Hanel <mh@synadia.com>
2020-12-16 14:34:09 -05:00
Ivan Kozlovic
a79a4d9834 Updated go mod/vendor due to PR #1737
The PR #1737 added a new file with an import of "golang.org/x/sys/unix"
but vendor directory was not updated.

Related to #1737

Signed-off-by: Ivan Kozlovic <ivan@synadia.com>
2020-12-16 12:19:31 -07:00
Derek Collison
3b18f188ed Switched behavior to never refuse new request, and to alert when expiring ones with interest
Signed-off-by: Derek Collison <derek@nats.io>
2020-10-21 10:35:29 -07:00
Derek Collison
610d2d21b7 More robust waiting queue for pull mode consumers
Signed-off-by: Derek Collison <derek@nats.io>
2020-10-19 19:51:46 -07:00
Matthias Hanel
2bfb8b1227 [Fixed] revocation check for activations used current time instead of jwt issue time
Signed-off-by: Matthias Hanel <mh@synadia.com>
2020-10-15 15:36:50 -04:00
Matthias Hanel
387e1e1ee4 [Fixed] revocation check used current time instead of jwt issue time
Also empty revoked keys once account jwt has no revocations.

Signed-off-by: Matthias Hanel <mh@synadia.com>
2020-10-06 21:45:34 -04:00
Matthias Hanel
08e37e0d94 Updated jwt library and check (account/token) issuer prior to jwt Validate
Signed-off-by: Matthias Hanel <mh@synadia.com>
2020-09-29 21:03:40 -04:00
Ivan Kozlovic
7ccbaca782 Added an allowed connection type filter for users
Users and NKey users will now have the option to specify a list
of allowed connection types.

This will allow for instance a certain user to be allowed to
connect as a standard NATS client, but not as Websocket, or
vice-versa.

This also fixes the websocket auth override. Indeed, with
the original behavior, the websocket users would have been bound
to $G, which would not work when there are accounts defined, since
when that is the case, no app can connect/bind to $G account.

Signed-off-by: Ivan Kozlovic <ivan@synadia.com>
2020-09-16 18:22:44 -06:00
Matthias Hanel
431560b004 Update JWT and incorporate change of cidr ranges from string to array
Signed-off-by: Matthias Hanel <mh@synadia.com>
2020-08-27 23:11:54 -04:00
Matthias Hanel
32615b4c71 Update jwtv2 and fix test that embedded jwtv2 operators
Signed-off-by: Matthias Hanel <mh@synadia.com>
2020-08-24 11:49:50 -04:00
Derek Collison
06ca580334 Update write deadline, client processing and slow proxy
Signed-off-by: Derek Collison <derek@nats.io>
2020-06-30 16:41:01 -07:00
Derek Collison
4dee03b587 Allow mixed TLS and non-TLS on same port
Signed-off-by: Derek Collison <derek@nats.io>
2020-06-05 18:04:11 -07:00
Matthias Hanel
cf6fcda75c Added default_permissions to accounts and account jwt
Signed-off-by: Matthias Hanel <mh@synadia.com>
2020-06-02 16:06:01 -04:00
Matthias Hanel
2d61507bb7 Moving nats.go unit test and updating go modules
Signed-off-by: Matthias Hanel <mh@synadia.com>
2020-06-02 12:44:00 -04:00
Matthias Hanel
547afa47d6 Pulling in updated jwtv2 and using server version stored in operator
Signed-off-by: Matthias Hanel <mh@synadia.com>
2020-06-01 18:08:50 -04:00
aricart
38d179c100 updated jwtv2 2020-06-01 18:01:12 -04:00
aricart
e7590f3065 jwt2 testbed 2020-06-01 18:00:13 -04:00
Derek Collison
19cf156d00 go.mod cleanup
Signed-off-by: Derek Collison <derek@nats.io>
2020-05-31 05:46:16 -07:00
Derek Collison
dbde2479c2 Add in headers to consumer delivered messages
Signed-off-by: Derek Collison <derek@nats.io>
2020-05-30 15:03:54 -07:00
Derek Collison
eca04c6fce First pass header support for JetStream
Signed-off-by: Derek Collison <derek@nats.io>
2020-05-30 10:04:23 -07:00
Derek Collison
c9f78d6f79 Fixes post rebasing with master
Signed-off-by: Derek Collison <derek@nats.io>
2020-05-19 16:38:19 -07:00
Derek Collison
d2ff4311d4 Rebase with master, updates to go.mod and vendor, bumped version
Signed-off-by: Derek Collison <derek@nats.io>
2020-05-19 14:20:02 -07:00
Derek Collison
f78efe2d91 Add Name to Observable info
Signed-off-by: Derek Collison <derek@nats.io>
2020-05-19 14:15:11 -07:00
Derek Collison
0d44a6150a More debug info on startup and restore
Signed-off-by: Derek Collison <derek@nats.io>
2020-05-19 14:15:11 -07:00
Derek Collison
79b85ae385 Optimize for concurrent pub/sub
Signed-off-by: Derek Collison <derek@nats.io>
2020-05-19 14:13:22 -07:00
Derek Collison
39aba7de92 filestore first pass
Signed-off-by: Derek Collison <derek@nats.io>
2020-05-19 14:12:28 -07:00
Matthias Hanel
84e52bfb44 Pointing to jwt master
Signed-off-by: Matthias Hanel <mh@synadia.com>
2020-05-19 16:06:22 -04:00
Matthias Hanel
a989024075 Picking up jwt branch corresponding to this change
Signed-off-by: Matthias Hanel <mh@synadia.com>
2020-05-18 18:57:39 -04:00
Ivan Kozlovic
b329215af3 Release v2.1.7
Signed-off-by: Ivan Kozlovic <ivan@synadia.com>
2020-05-13 19:40:49 -06:00
Ivan Kozlovic
182e30adb6 Update dependencies
Signed-off-by: Ivan Kozlovic <ivan@synadia.com>
2020-03-30 18:23:43 -06:00
Ivan Kozlovic
4a03b6382e Release 2.1.2
Signed-off-by: Ivan Kozlovic <ivan@synadia.com>
2019-11-18 15:22:52 -07:00
Derek Collison
fccf147898 Updated JWT dependency
Signed-off-by: Derek Collison <derek@nats.io>
2019-09-20 10:13:09 -07:00
Derek Collison
0551371b31 Add in JWT support for tracking latency
Signed-off-by: Derek Collison <derek@nats.io>
2019-09-18 08:51:43 -07:00
Ivan Kozlovic
07e3db6b8e Prepare for v2.0.4 with goreleaser
Also fixed some flappers

Signed-off-by: Ivan Kozlovic <ivan@synadia.com>
2019-08-15 09:06:56 -06:00
Stephen Asbury
4d63709852 Added support for service response types
Test checks that response types are initialized
Updated to latest JWT library with response types
Updated jwt in vendor
2019-08-09 17:54:17 -07:00
Derek Collison
bf902d9e7c Add in user JWT support for ResponsePermissions
Signed-off-by: Derek Collison <derek@nats.io>
2019-07-26 16:15:13 -07:00
Derek Collison
2cad1055c7 Update modules and vendor
Signed-off-by: Derek Collison <derek@nats.io>
2019-07-11 11:34:32 -07:00
Ivan Kozlovic
61e062dfc9 fix nats.go dependency
Signed-off-by: Ivan Kozlovic <ivan@synadia.com>
2019-06-04 09:44:07 -06:00
Ivan Kozlovic
ed1901c792 Update go.mod to satisfy v2 requirements
Signed-off-by: Ivan Kozlovic <ivan@synadia.com>
2019-06-03 19:45:47 -06:00
Derek Collison
3cf6f6a5d2 Bug fix for service import with leafnodes and gws
Signed-off-by: Derek Collison <derek@nats.io>
2019-05-31 11:22:02 -07:00
Derek Collison
d7140a0fd1 Update for client rename
Signed-off-by: Derek Collison <derek@nats.io>
2019-05-10 15:11:30 -07:00
Derek Collison
acfe372d63 Changes for rename from gnatsd -> nats-server
Signed-off-by: Derek Collison <derek@nats.io>
2019-05-06 15:04:24 -07:00
Alberto Ricart
84a7e289b0 Added support for account signing keys. (#962)
* Added support for account signing keys. When account signing keys change
the validity of the client JWT and token imports need to be checked as well
as it is possible for the signing key used to sign the user or import
token to have been removed from the source account.
2019-04-18 19:08:26 -05:00
Derek Collison
0f98b1506f Update to gomod with vendor directory, update vendored pkgs
Signed-off-by: Derek Collison <derek@nats.io>
2019-04-09 17:41:57 -07:00