add a newline after dumped payloads
Ted Unangst tedu@tedunangst.com
Wed, 18 May 2022 14:46:38 -0400
1 files changed,
4 insertions(+),
0 deletions(-)
jump to
M
web.go
→
web.go
@@ -341,6 +341,7 @@ j, err := junk.FromBytes(payload)
if err != nil { ilog.Printf("bad payload: %s", err) ilog.Writer().Write(payload) + ilog.Writer().Write([]byte{'\n'}) return }@@ -367,6 +368,7 @@ ilog.Printf("inbox message failed signature for %s from %s: %s", keyname, r.Header.Get("X-Forwarded-For"), err)
if keyname != "" { ilog.Printf("bad signature from %s", keyname) ilog.Writer().Write(payload) + ilog.Writer().Write([]byte{'\n'}) } http.Error(w, "what did you call me?", http.StatusTeapot) return@@ -456,6 +458,7 @@ j, err := junk.FromBytes(payload)
if err != nil { ilog.Printf("bad payload: %s", err) ilog.Writer().Write(payload) + ilog.Writer().Write([]byte{'\n'}) return } if crappola(j) {@@ -471,6 +474,7 @@ ilog.Printf("inbox message failed signature for %s from %s: %s", keyname, r.Header.Get("X-Forwarded-For"), err)
if keyname != "" { ilog.Printf("bad signature from %s", keyname) ilog.Writer().Write(payload) + ilog.Writer().Write([]byte{'\n'}) } http.Error(w, "what did you call me?", http.StatusTeapot) return