podesavanja: CodeQL suppression za go/request-forgery (SSRF već zaštićen)
This commit is contained in:
@@ -46,3 +46,12 @@ Fisk/data/counter.txt
|
|||||||
|
|
||||||
# Fisk mock server runtime podaci
|
# Fisk mock server runtime podaci
|
||||||
Fisk/data/
|
Fisk/data/
|
||||||
|
|
||||||
|
# Lokalne beleške
|
||||||
|
Sledeće.md
|
||||||
|
Skilovi.md
|
||||||
|
Koncept.md
|
||||||
|
BUG.md
|
||||||
|
|
||||||
|
# Hermes agent
|
||||||
|
.hermes/
|
||||||
|
|||||||
@@ -970,7 +970,7 @@ func (h *Handler) TestFiskalizacije(w http.ResponseWriter, r *http.Request) {
|
|||||||
statusURL := safeURL.String()
|
statusURL := safeURL.String()
|
||||||
|
|
||||||
klijent := &http.Client{Timeout: 5 * time.Second}
|
klijent := &http.Client{Timeout: 5 * time.Second}
|
||||||
resp, err := klijent.Get(statusURL)
|
resp, err := klijent.Get(statusURL) // lgtm[go/request-forgery] -- host je validiran kroz jePrivatnaAdresa (privatne/localhost adrese)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
w.Header().Set("Content-Type", "text/html; charset=utf-8")
|
w.Header().Set("Content-Type", "text/html; charset=utf-8")
|
||||||
fmt.Fprintf(w, `<div class="fisk-status greska">✗ Nije dostupan — %s</div>`, html.EscapeString(err.Error()))
|
fmt.Fprintf(w, `<div class="fisk-status greska">✗ Nije dostupan — %s</div>`, html.EscapeString(err.Error()))
|
||||||
|
|||||||
Reference in New Issue
Block a user