Commit graph

597 commits

Author SHA1 Message Date
Pēteris Caune
148894bd9e
Upgrade to Bootstrap 3.4.1 2021-10-01 12:21:54 +03:00
Pēteris Caune
27da637e86
Fix Dockerfile to correctly build cryptography==35.0.0 on 32-bit arm
Fixes: #565

Also, split Dockerfile into two stages, so rust
and other build dependencies don't end up in the final image.

Note cryptography has binary wheels for various architectures,
but unfortunately not for 32-bit arm. And, starting from v35.0.0,
cryptography requires rust to build from source.
2021-10-01 09:53:48 +03:00
Pēteris Caune
6e3a1c790d
Fix the ping handler to reject status codes > 255 2021-09-15 11:36:15 +03:00
Pēteris Caune
f8131741ef
Fix minor API inconsistencies
1. Drop API support for GET, DELETE requests with a request body.
Healthchecks had an undocumented quirk where you could authenticate a
GET or DELETE request by putting a '{"api_key":"..."}' in request body.
This commit removes this feature.

Note: POST requests can still authenticate either by sending
a X-Api-Key header, or by putting a "api_key" key in request body.
GET and DELETE requests can now only authenticate with the
request header.

2. Add missing @csrf_exempt annotations in API views
When client sends a HTTP POST request to a GET-only endpoint,
the server is supposed to respond with "405 Method Not Allowed".
Due to CSRF checking, a couple endpoints were responding with
"403 Forbidden" instead. Adding @csrf_exempt annotations fixes
the problem.
2021-09-10 22:49:12 +03:00
Pēteris Caune
3dfdbc09ca
Add ability to create/revoke individual keys 2021-09-09 14:55:17 +03:00
Pēteris Caune
8541ec59ca
Add ability to edit existing WhatsApp integrations 2021-08-26 10:17:01 +03:00
Pēteris Caune
5af09ed4dd
Add ability to edit existing Signal integrations 2021-08-26 10:01:09 +03:00
Pēteris Caune
3807c200ce
Add ability to edit existing SMS integrations 2021-08-26 09:42:35 +03:00
Pēteris Caune
2a9a544ddf
Add ability to edit existing email integrations 2021-08-25 18:04:54 +03:00
Pēteris Caune
98eb7cc14a
Add /api/v1/badges/ endpoint
cc: #552
2021-08-18 17:47:57 +03:00
Pēteris Caune
1247cc4ea7
Fix a crash during login when user's profile does not exist
Fixes: #77
2021-08-18 10:32:10 +03:00
Pēteris Caune
b43612806f
Fix dark mode bug in selectpicker widgets 2021-08-10 16:47:47 +03:00
Pēteris Caune
544ec7ea69
Add handling for non-latin-1 characters in webhook headers 2021-08-10 10:36:58 +03:00
Pēteris Caune
2a9bc42dd4
Update Changelog for v1.22.0 release 2021-08-06 14:27:15 +03:00
Pēteris Caune
7252f2f101
Fix _allow_redirect function to reject absolute URLs
This fixes a security issue:
- attacker can crafts a redirect URL to an external site
- attacker gets victim to click on it
- victim logs in
- after login, Healthchecks redirects victim to the external site

The _allow_redirect function now additionally
requires the redirect URL is relative (has no scheme or domain).
2021-08-06 13:34:40 +03:00
Pēteris Caune
e6427995b7
Add Whitenoise and improve README
Fixes: #548
2021-08-05 18:06:47 +03:00
Pēteris Caune
222722569e
Add support for 2FA using TOTP
Fixes: #354
2021-07-30 16:43:23 +03:00
Pēteris Caune
4f83f8c06b
Fix a 403 when transferring a project to a read-only team member 2021-07-26 12:50:43 +03:00
Pēteris Caune
e46000ecdf
Add admin action to log in as any user 2021-07-20 11:16:12 +03:00
Pēteris Caune
2382bf6722
Add SITE_LOGO_URL setting
Fixes: #323
2021-07-16 15:30:34 +03:00
Pēteris Caune
dd88924660
Fix dark mode styling issues in Cron Syntax Cheatsheet 2021-07-16 12:25:16 +03:00
Pēteris Caune
99bb71c920
Use multicolor channel icons for better appearance in the dark mode 2021-07-07 15:23:02 +03:00
Pēteris Caune
5a4c06ffae
Update CHANGELOG for v1.21.0 release 2021-07-02 16:52:24 +03:00
Pēteris Caune
d243f502d3
Fix off-by-one-month error in monthly reports, downtime columns
Fixes: #539
2021-07-02 15:22:51 +03:00
Pēteris Caune
2d20f439dd
Remove PagerDuty Connect
PagerDuty Connect is deprecated and will be discontinued.
It is replaced by PagerDuty Simple Install Flow (see
README for setup instructions).
2021-06-21 10:44:21 +03:00
Pēteris Caune
c5229d6505
Add CSS for dark mode 2021-06-16 15:23:34 +03:00
Pēteris Caune
fd7ab5e767
Implement PagerDuty Simple Install Flow 2021-06-16 14:18:32 +03:00
Pēteris Caune
df44ee58c0
Add an option for weekly reports (in addition to monthly) 2021-05-24 13:44:34 +03:00
Pēteris Caune
855d188981
Add support for "... is UP" SMS notifications
Fixes: #512
2021-05-21 12:57:23 +03:00
Pēteris Caune
e090aa5403
Improve the handling of unknown email addresses in the Sign In form 2021-05-12 13:49:56 +03:00
Pēteris Caune
ae4487b6c3
Update to Django 3.2.2 2021-05-06 11:07:51 +03:00
Pēteris Caune
64f2e86051
Increase "Success / Failure Keywords" field lengths to 200 2021-05-06 11:00:36 +03:00
Pēteris Caune
e2b96d9bd8
Update CHANGELOG for v1.20.0 release 2021-04-22 13:03:07 +03:00
Pēteris Caune
738a648407
Improve project sorting in the "My Projects" page
Primary sort key: projects with overall_status=down go first
Secondary sort key: project's name
2021-04-14 16:18:43 +03:00
Pēteris Caune
78652b5659
Upgrade Django version to 3.2 2021-04-07 11:39:11 +03:00
Pēteris Caune
67d11e8d40
Fix the month boundary calculation in monthly reports
Fixes: #497
2021-04-02 13:49:55 +03:00
Pēteris Caune
68b1d5bb8b
Fix the "Email Reports" screen to clear Profile.next_nag_date 2021-03-15 13:06:57 +02:00
Pēteris Caune
05db43f95d
Fix the pause action to clear Profile.next_nag_date if all checks up 2021-03-15 12:52:35 +02:00
Pēteris Caune
7ba5fcbb71
Fix sendalerts to clear Profile.next_nag_date if all checks up
Profile.next_nag_date tracks when the next hourly/daily reminder
should be sent. Normally, sendalerts sets this field when
a check goes down, and sendreports clears it out whenever
it is about to send a reminder but realizes all checks are up.

The problem: sendalerts can set next_nag_date to a non-null
value, but it does not clear it out when all checks are up.
This can result in a hourly/daily reminder being sent out
at the wrong time. Specific example, assuming hourly reminders:

13:00: Check A goes down. next_nag_date gets set to 14:00.
13:05: Check A goes up. next_nag_date remains set to 14:00.
13:55: Check B goes down. next_nag_date remains set to 14:00.
14:00: Healthchecks sends a hourly reminder, just 5 minutes
       after Check B going down. It should have sent the reminder
       at 13:55 + 1 hour = 14:55

The fix: sendalerts can now both set and clear the next_nag_date
field. The main changes are in Project.update_next_nag_dates()
and in Profile.update_next_nag_date(). With the fix:

13:00: Check A goes down. next_nag_date gets set to 14:00.
13:05: Check A goes up. next_nag_date gets set to null.
13:55: Check B goes down. next_nag_date gets set to 14:55.
14:55: Healthchecks sends a hourly reminder.
2021-03-15 12:34:39 +02:00
Pēteris Caune
2bfea987e9
Replace details_url with cloaked_url in email and chat notifications 2021-03-04 16:55:05 +02:00
Pēteris Caune
5321f772fe
Add a link to check's details page in Slack notifications
Fixes: #486
2021-03-04 15:51:35 +02:00
Pēteris Caune
46bc7d8306
Improve HTML email display in the "Ping Details" dialog 2021-02-26 16:25:39 +02:00
Pēteris Caune
2a63d24812
Add a "Subject" field in the "Ping Details" dialog 2021-02-26 11:19:44 +02:00
Pēteris Caune
1bc89f0d5d
Implement email body decoding in the "Ping Details" dialog 2021-02-23 17:34:33 +02:00
Pēteris Caune
1e84cac37d
Relax cron expression validation
Accept all expressions that croniter accepts.
If cron-descriptor throws an exception, don't show the
description to the user.
2021-02-09 11:34:53 +02:00
Pēteris Caune
c1f433bb71
Rename VictorOps -> Splunk On-Call 2021-02-03 16:09:24 +02:00
Pēteris Caune
5979204691
Fix downtime summary to handle months when the check didn't exist
Fixes: #472
2021-02-03 14:27:06 +02:00
Pēteris Caune
0a0b48a3fe
Update CHANGELOG for v1.19.0 release 2021-02-03 10:57:39 +02:00
Pēteris Caune
67560c96e1
Change icon CSS class prefix to work around Fanboy's filter list
Problem: if you use uBlock Origin, and enable the
"Fanboy's Social" filter list, Healthchecks does not show
Telegram or WhatsApp icons. This is because the filter list
contains "##.icon-telegram" and "##.icon-whatsapp" entries.

This commit changes the CSS class prefix to "ic-". So we're
now using icon classes like "ic-telegram" and "ic-whatsapp".

As a bonus, we save 2 bytes in HTML per displayed icon :-)
2021-02-03 10:44:35 +02:00
Pēteris Caune
65ace8238a
Add the ZULIP_ENABLED setting 2021-02-03 09:11:32 +02:00