vault/logical/framework
Jeff Mitchell ca55573d38
Strip empty strings from database revocation stmts (#5955)
* Strip empty strings from database revocation stmts

It's technically valid to give empty strings as statements to run on
most databases. However, in the case of revocation statements, it's not
only generally inadvisable but can lead to lack of revocations when you
expect them. This strips empty strings from the array of revocation
statements.

It also makes two other changes:

* Return statements on read as empty but valid arrays rather than nulls,
so that typing information is inferred (this is more in line with the
rest of Vault these days)

* Changes field data for TypeStringSlice and TypeCommaStringSlice such
that a client-supplied value of `""` doesn't turn into `[]string{""}`
but rather `[]string{}`.

The latter and the explicit revocation statement changes are related,
and defense in depth.
2018-12-14 09:12:26 -05:00
..
testdata Framework and API changes to support OpenAPI (#5546) 2018-11-05 12:24:39 -08:00
backend_test.go Framework and API changes to support OpenAPI (#5546) 2018-11-05 12:24:39 -08:00
backend.go Framework and API changes to support OpenAPI (#5546) 2018-11-05 12:24:39 -08:00
field_data_test.go Strip empty strings from database revocation stmts (#5955) 2018-12-14 09:12:26 -05:00
field_data.go Strip empty strings from database revocation stmts (#5955) 2018-12-14 09:12:26 -05:00
field_type.go Add a header type field (#4993) 2018-08-13 11:02:44 -07:00
lease_test.go Core handling of TTLs (#4230) 2018-04-03 12:20:20 -04:00
lease.go Core handling of TTLs (#4230) 2018-04-03 12:20:20 -04:00
openapi_test.go Update OpenAPI path parsing of alternation parameters (#5710) 2018-11-06 15:04:30 -08:00
openapi.go Add operationId field to OpenAPI output (#5876) 2018-12-12 13:59:23 -08:00
path_map_test.go Add context to the NewSalt function (#4102) 2018-03-08 11:21:11 -08:00
path_map.go Add context to the NewSalt function (#4102) 2018-03-08 11:21:11 -08:00
path_struct_test.go Add context to storage backends and wire it through a lot of places (#3817) 2018-01-19 01:44:44 -05:00
path_struct.go Add context to storage backends and wire it through a lot of places (#3817) 2018-01-19 01:44:44 -05:00
path_test.go Framework and API changes to support OpenAPI (#5546) 2018-11-05 12:24:39 -08:00
path.go Framework and API changes to support OpenAPI (#5546) 2018-11-05 12:24:39 -08:00
policy_map_test.go Add context to storage backends and wire it through a lot of places (#3817) 2018-01-19 01:44:44 -05:00
policy_map.go Add context to storage backends and wire it through a lot of places (#3817) 2018-01-19 01:44:44 -05:00
secret_test.go vault: clean up VaultID duplications, make secret responses clearer 2015-03-19 23:11:42 +01:00
secret.go Pass context to backends (#3750) 2018-01-08 10:31:38 -08:00
template.go Errwrap everywhere (#4252) 2018-04-05 11:49:21 -04:00
testing.go logical/framework: PathMap allows hyphens in keys [GH-119] 2015-05-02 13:17:42 -07:00
wal_test.go Add context to storage backends and wire it through a lot of places (#3817) 2018-01-19 01:44:44 -05:00
wal.go Add context to storage backends and wire it through a lot of places (#3817) 2018-01-19 01:44:44 -05:00