From 4dda0b72122925defadb9e23df92a84367b416db Mon Sep 17 00:00:00 2001 From: Nick Cabatoff Date: Wed, 15 May 2019 08:41:52 -0400 Subject: [PATCH] Copy LogInput from audit package, adding Type field and making Request and Response interface{}. The one in audit will go away in a subsequent changeset. Add OptMarshaler interface for doing JSON marshaling with options. --- sdk/logical/audit.go | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 sdk/logical/audit.go diff --git a/sdk/logical/audit.go b/sdk/logical/audit.go new file mode 100644 index 000000000000..f3bf622b3d97 --- /dev/null +++ b/sdk/logical/audit.go @@ -0,0 +1,19 @@ +package logical + +type LogInput struct { + Type string + Auth *Auth + Request interface{} + Response interface{} + OuterErr error + NonHMACReqDataKeys []string + NonHMACRespDataKeys []string +} + +type MarshalOptions struct { + ValueHasher func(string) string +} + +type OptMarshaler interface { + MarshalJSONWithOptions(*MarshalOptions) ([]byte, error) +}