Rework webhook signature header to align with larger implementations and defined standards at https://superfeedr-misc.s3.amazonaws.com/pubsubhubbub-core-0.4.html\#authednotify
parent
3dd0e8fc79
commit
e8dae79ce0
|
@ -33,5 +33,6 @@ answer newbie questions, and generally made taiga that much better:
|
|||
- Motius GmbH <mail@motius.de>
|
||||
- Riccardo Coccioli <riccardo.coccioli@immobiliare.it>
|
||||
- Ricky Posner <e@eposner.com>
|
||||
- Stefan Auditor <stefan.auditor@erdfisch.de>
|
||||
- Yamila Moreno <yamila.moreno@kaleidos.net>
|
||||
- Yaser Alraddadi <yaser@yr.sa>
|
||||
|
|
|
@ -30,6 +30,7 @@
|
|||
- Improve messages generated on webhooks input.
|
||||
- Add mentions support in commit messages.
|
||||
- Cleanup hooks code.
|
||||
- Rework webhook signature header to align with larger implementations and defined [standards](https://superfeedr-misc.s3.amazonaws.com/pubsubhubbub-core-0.4.html\#authednotify). (thanks to [Stefan Auditor](https://github.com/sanduhrs))
|
||||
- Add created-, modified-, finished- and finish_date queryset filters
|
||||
- Support exact match, gt, gte, lt, lte
|
||||
- added issues, tasks and userstories accordingly
|
||||
|
|
|
@ -66,7 +66,8 @@ def _send_request(webhook_id, url, key, data):
|
|||
serialized_data = UnicodeJSONRenderer().render(data)
|
||||
signature = _generate_signature(serialized_data, key)
|
||||
headers = {
|
||||
"X-TAIGA-WEBHOOK-SIGNATURE": signature,
|
||||
"X-TAIGA-WEBHOOK-SIGNATURE": signature, # For backward compatibility
|
||||
"X-Hub-Signature": "sha1={}".format(signature),
|
||||
"Content-Type": "application/json"
|
||||
}
|
||||
request = requests.Request('POST', url, data=serialized_data, headers=headers)
|
||||
|
|
Loading…
Reference in New Issue