Lasa is a stateless proxy that generates a RSS or an Atom feed from a Standard.site publication. lasa.anhgelus.world
rss atom atprotocol standard-site atproto
2
fork

Configure Feed

Select the types of activity you want to include in your feed.

fix(server): not using headers for getting IP

+9 -1
+1
Dockerfile
··· 21 21 LABEL org.opencontainers.image.url='https://tangled.org/anhgelus.world/lasa' 22 22 LABEL org.opencontainers.image.licenses='AGPL-3-only' 23 23 24 + COPY README.md . 24 25 COPY --from=builder /app/build/lasad . 25 26 COPY --from=builder /app/build/lasa . 26 27
+8 -1
cmd/lasad/server/limiter.go
··· 38 38 } 39 39 40 40 func (l *Limiter) handle(w *internal.StatusWriter, r *http.Request) { 41 - ip, _, _ := strings.Cut(r.RemoteAddr, ":") 41 + addr := r.Header.Get("X-Real-Ip") 42 + if addr == "" { 43 + addr = r.Header.Get("X-Forwarded-For") 44 + } 45 + if addr == "" { 46 + addr = r.RemoteAddr 47 + } 48 + ip, _, _ := strings.Cut(addr, ":") 42 49 if w.Code != http.StatusNotFound && w.Code != http.StatusBadRequest && w.Code != http.StatusTooManyRequests { 43 50 return 44 51 }