mirror of
https://github.com/github/codeql.git
synced 2025-12-16 16:53:25 +01:00
16 lines
236 B
Go
16 lines
236 B
Go
package main
|
|
|
|
import (
|
|
"io"
|
|
"net/http"
|
|
"os"
|
|
)
|
|
|
|
func ListFiles(w http.ResponseWriter, r *http.Request) {
|
|
files, _ := os.ReadDir(".")
|
|
|
|
for _, file := range files {
|
|
io.WriteString(w, file.Name()+"\n") // $ Alert[go/stored-xss]
|
|
}
|
|
}
|