Semir Patel
3fb8dda960
[BACKPORT] 1.16.x manual backport of OSS->CE branch ( #18549 )
2023-08-23 11:53:44 -05:00
Ronald
7a5c8dc1eb
Copyright headers for command folder ( #16705 )
...
* copyright headers for agent folder
* Ignore test data files
* fix proto files and remove headers in agent/uiserver folder
* ignore deep-copy files
* copyright headers for agent folder
* Copyright headers for command folder
* fix merge conflicts
2023-03-28 15:12:30 -04:00
skpratt
9718079a49
ACL error improvements: incomplete bootstrapping and non-existent token ( #16105 )
...
* add bootstrapping detail for acl errors
* error detail improvements
* update acl bootstrapping test coverage
* update namespace errors
* update test coverage
* add changelog
* update message for unbootstrapped error
* consolidate error message code and update changelog
* logout message change
2023-02-08 23:49:44 +00:00
Kyle Schochenmaier
2b1e5f69e2
removes ioutil usage everywhere which was deprecated in go1.16 ( #15297 )
...
* update go version to 1.18 for api and sdk, go mod tidy
* removes ioutil usage everywhere which was deprecated in go1.16 in favour of io and os packages. Also introduces a lint rule which forbids use of ioutil going forward.
Co-authored-by: R.B. Boyer <4903+rboyer@users.noreply.github.com>
2022-11-10 10:26:01 -06:00
R.B. Boyer
12523197f9
syncing changes back from enterprise ( #12701 )
2022-04-05 15:46:56 -05:00
Chris S. Kim
ead530bc48
Add partitions to prettyformatters ( #11789 )
2021-12-09 15:58:45 -05:00
Dan Upton
4192468358
Remove references to "master" ACL tokens in tests ( #11751 )
2021-12-07 12:48:50 +00:00
R.B. Boyer
83bf7ab3ff
re-run gofmt on 1.17 ( #11579 )
...
This should let freshly recompiled golangci-lint binaries using Go 1.17
pass 'make lint'
2021-11-16 12:04:01 -06:00
Oleg Butuzov
942c91b965
refactor: replace (*bytes.Buffer).WriteString with (*bytes.Buffer).Write
...
This PR change one method of bytes.Buffer struct package with a similar
one, as result - code produce less allocations on heap.
2021-10-20 09:36:53 +03:00
R.B. Boyer
c9c80b5ef6
add partition cli flag to all cli commands that have namespace flag ( #10668 )
2021-07-21 14:45:24 -05:00
Daniel Nephin
ef0999547a
testing: skip slow tests with -short
...
Add a skip condition to all tests slower than 100ms.
This change was made using `gotestsum tool slowest` with data from the
last 3 CI runs of master.
See https://github.com/gotestyourself/gotestsum#finding-and-skipping-slow-tests
With this change:
```
$ time go test -count=1 -short ./agent
ok github.com/hashicorp/consul/agent 0.743s
real 0m4.791s
$ time go test -count=1 -short ./agent/consul
ok github.com/hashicorp/consul/agent/consul 4.229s
real 0m8.769s
```
2020-12-07 13:42:55 -05:00
Ryan Ooi
ae6cc78f91
add tailing backtick
2020-10-07 07:14:56 +08:00
Ryan Ooi
2ce398b62a
Update acl-method command example
2020-10-07 06:44:24 +08:00
Daniel Nephin
8d35e37b3c
testing: Remove all the defer os.Removeall
...
Now that testutil uses t.Cleanup to remove the directory the caller no longer has to manage
the removal
2020-08-14 19:58:53 -04:00
Matt Keeler
2c7844d220
Implement Client Agent Auto Config
...
There are a couple of things in here.
First, just like auto encrypt, any Cluster.AutoConfig RPC will implicitly use the less secure RPC mechanism.
This drastically modifies how the Consul Agent starts up and moves most of the responsibilities (other than signal handling) from the cli command and into the Agent.
2020-06-17 16:49:46 -04:00
R.B. Boyer
7bd7895047
acl: allow auth methods created in the primary datacenter to optionally create global tokens ( #7899 )
2020-06-01 11:44:47 -05:00
R.B. Boyer
c54211ad52
cli: ensure 'acl auth-method update' doesn't deep merge the Config field ( #7839 )
2020-05-11 14:21:17 -05:00
R.B. Boyer
bf70ad1802
cli: oss refactors to support making the auth method CLI aware of namespace rules in enterprise ( #7812 )
2020-05-07 17:08:42 -05:00
R.B. Boyer
095f0503e8
test: make auth method cli crud test work in both oss and ent ( #7800 )
2020-05-06 15:16:50 -05:00
R.B. Boyer
ea21280636
test: make auth method cli crud test helper ignore the default namespace ( #7799 )
2020-05-06 15:09:47 -05:00
R.B. Boyer
c9c557477b
acl: add MaxTokenTTL field to auth methods ( #7779 )
...
When set to a non zero value it will limit the ExpirationTime of all
tokens created via the auth method.
2020-05-04 17:02:57 -05:00
s-christoff
2535cb85eb
cli: Add -config flag to "acl authmethod update/create" ( #7776 )
2020-05-04 16:21:28 -05:00
R.B. Boyer
265d2ea9e1
acl: add DisplayName field to auth methods ( #7769 )
...
Also add a few missing acl fields in the api.
2020-05-04 15:18:25 -05:00
Daniel Nephin
8b6877febd
Remove name from NewTestAgent
...
Using:
git grep -l 'NewTestAgent(t, t.Name(),' | \
xargs sed -i -e 's/NewTestAgent(t, t.Name(),/NewTestAgent(t,/g'
2020-03-31 16:13:44 -04:00
Artur Mullakhmetov
e5b3b329ea
Add ACL CLI commands output format option.
...
Add command level formatter, that incapsulates command output printing
logiс that depends on the command `-format` option.
Move Print* functions from acl_helpers to prettyFormatter. Add jsonFormatter.
2020-03-26 19:05:10 +03:00
Chris Piraino
3dd0b59793
Allow users to configure either unstructured or JSON logging ( #7130 )
...
* hclog Allow users to choose between unstructured and JSON logging
2020-01-28 17:50:41 -06:00
Matt Keeler
b9996e6bbe
Add Namespace support to the API module and the CLI commands ( #6874 )
...
Also update the Docs and fixup the HTTP API to return proper errors when someone attempts to use Namespaces with an OSS agent.
Add Namespace HTTP API docs
Make all API endpoints disallow unknown fields
2019-12-06 11:14:56 -05:00
R.B. Boyer
41dac76ab3
docs: add documentation for all secure acl introduction work ( #5640 )
2019-05-01 16:11:23 -05:00
R.B. Boyer
5a505c5b3a
acl: adding support for kubernetes auth provider login ( #5600 )
...
* auth providers
* binding rules
* auth provider for kubernetes
* login/logout
2019-04-26 14:49:25 -05:00