beego: fixed serious Directory Traversal

This commit is contained in:
astaxie 2014-04-08 17:43:25 +08:00
parent 4124760706
commit 18fee2ad9a
1 changed files with 1 additions and 1 deletions

View File

@ -13,7 +13,7 @@ import (
)
func serverStaticRouter(ctx *context.Context) bool {
requestPath := ctx.Input.Request.URL.Path
requestPath := path.Clean(ctx.Input.Request.URL.Path)
for prefix, staticDir := range StaticDir {
if len(prefix) == 0 {
continue