X-Git-Url: https://git.octo.it/?p=kraftakt.git;a=blobdiff_plain;f=kraftakt.go;h=72389bd1430b36450a071d09d8a491597d4805d7;hp=40f054615234863d5f3adc3ac8176c9981fdec5c;hb=HEAD;hpb=a05bb612a8b3c7b66fc6f841040c69b87350e63e diff --git a/kraftakt.go b/kraftakt.go index 40f0546..72389bd 100644 --- a/kraftakt.go +++ b/kraftakt.go @@ -258,13 +258,9 @@ func fitbitNotifyHandler(ctx context.Context, w http.ResponseWriter, r *http.Req // Fitbit recommendation: "If signature verification fails, you should // respond with a 404" if !fitbit.CheckSignature(ctx, data, r.Header.Get("X-Fitbit-Signature")) { - /* - log.Errorf(ctx, "signature mismatch") - w.WriteHeader(http.StatusNotFound) - return nil - */ - } else { - log.Warningf(ctx, "TODO(octo): re-enable signature checking, see https://community.fitbit.com/t5/Web-API-Development/Push-notification-signatures-are-currently-invalid/m-p/2496159") + log.Errorf(ctx, "signature mismatch") + w.WriteHeader(http.StatusNotFound) + return nil } if err := delayedHandleNotifications.Call(ctx, data); err != nil {