notification-controller/api/v1beta1
Max Jonas Werner a76b9a0c63
Add "generic-hmac" Provider
This commit adds the "generic-hmac" Provider type for authenticating
webhook requests coming from notification-controller. I extended the
`Forwarder` notifier to accept an optional key used for generating the
HMAC. If the key is nil or empty no HMAC header is generated and the
forwarder behaves as before. If it is provided an `X-Signature` HTTP
header is added to the request carrying the HMAC.

I transformed the `TestForwarder_Post` test into a table-driven test
so that we can use the same setup and testing code for testing HMAC
and non-HMAC forwarder instances.

Any existing `X-Signature` header value set through
a `Provider.spec.secretRef` Secret's `header` field will be
overwritten.

closes #99

Signed-off-by: Max Jonas Werner <max@e13.dev>
2022-10-04 18:41:45 +02:00
..
alert_types.go api: Move Status in CRD printcolumn to the end 2022-02-24 02:12:36 +05:30
condition_types.go Add finalizers to all the CRDs 2022-09-09 15:18:11 +01:00
doc.go Change copyright to Flux authors 2020-10-27 18:52:14 +02:00
groupversion_info.go Change copyright to Flux authors 2020-10-27 18:52:14 +02:00
provider_types.go Add "generic-hmac" Provider 2022-10-04 18:41:45 +02:00
receiver_types.go api: Move Status in CRD printcolumn to the end 2022-02-24 02:12:36 +05:30
reference_types.go Add OCIRepository event source kind 2022-08-03 17:25:56 +05:30
zz_generated.deepcopy.go Add .spec.timeout to Provider 2022-08-31 11:25:09 +01:00