vault/builtin/logical
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
..
aws Run all builtins as plugins (#5536) 2018-11-06 17:21:24 -08:00
cassandra Run all builtins as plugins (#5536) 2018-11-06 17:21:24 -08:00
consul Run all builtins as plugins (#5536) 2018-11-06 17:21:24 -08:00
database Strip empty strings from database revocation stmts (#5955) 2018-12-14 09:12:26 -05:00
mongodb Run all builtins as plugins (#5536) 2018-11-06 17:21:24 -08:00
mssql Run all builtins as plugins (#5536) 2018-11-06 17:21:24 -08:00
mysql Run all builtins as plugins (#5536) 2018-11-06 17:21:24 -08:00
nomad Make builtin auth and secret plugins buildable (#5456) 2018-10-09 09:29:20 -07:00
pki Remove an empty line for /pki/ca_chain (#5779) 2018-12-12 15:38:35 -05:00
postgresql Run all builtins as plugins (#5536) 2018-11-06 17:21:24 -08:00
rabbitmq Run all builtins as plugins (#5536) 2018-11-06 17:21:24 -08:00
ssh Fix tests 2018-12-11 15:04:02 -05:00
totp Run all builtins as plugins (#5536) 2018-11-06 17:21:24 -08:00
transit Run all builtins as plugins (#5536) 2018-11-06 17:21:24 -08:00