all repos — honk @ 50f95bddb9b41e5c65c52475d3328705dc49183b

my fork of honk

reject origin test in getjunk path to catch strays
Ted Unangst tedu@tedunangst.com
Sat, 05 Aug 2023 20:52:55 -0400
commit

50f95bddb9b41e5c65c52475d3328705dc49183b

parent

d3a951e7f475a2650f6b9640fdfe31b53ad21600

1 files changed, 3 insertions(+), 0 deletions(-)

jump to
M activity.goactivity.go

@@ -133,6 +133,9 @@

var signGets = true func GetJunkTimeout(userid int64, url string, timeout time.Duration) (junk.Junk, error) { + if rejectorigin(userid, url, false) { + return nil, fmt.Errorf("rejected origin: %s", url) + } client := http.DefaultClient sign := func(req *http.Request) error { var ki *KeyInfo