Commit 59a67720 authored by astaxie's avatar astaxie

xsrf's defaut time set to 0 & fix ts not use

parent 93e1206d
...@@ -77,7 +77,7 @@ func init() { ...@@ -77,7 +77,7 @@ func init() {
HttpServerTimeOut = 0 HttpServerTimeOut = 0
ErrorsShow = true ErrorsShow = true
XSRFKEY = "beegoxsrf" XSRFKEY = "beegoxsrf"
XSRFExpire = 60 XSRFExpire = 0
TemplateLeft = "{{" TemplateLeft = "{{"
TemplateRight = "}}" TemplateRight = "}}"
ParseConfig() ParseConfig()
......
...@@ -323,8 +323,6 @@ func (c *Controller) GetSecureCookie(Secret, key string) (string, bool) { ...@@ -323,8 +323,6 @@ func (c *Controller) GetSecureCookie(Secret, key string) (string, bool) {
return "", false return "", false
} }
ts, _ := strconv.ParseInt(timestamp, 0, 64)
buf := bytes.NewBufferString(val) buf := bytes.NewBufferString(val)
encoder := base64.NewDecoder(base64.StdEncoding, buf) encoder := base64.NewDecoder(base64.StdEncoding, buf)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment