aboutsummaryrefslogtreecommitdiff
path: root/vendor/github.com/gorilla/csrf/csrf.go
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/github.com/gorilla/csrf/csrf.go')
-rw-r--r--vendor/github.com/gorilla/csrf/csrf.go22
1 files changed, 13 insertions, 9 deletions
diff --git a/vendor/github.com/gorilla/csrf/csrf.go b/vendor/github.com/gorilla/csrf/csrf.go
index 926be23..cc7878f 100644
--- a/vendor/github.com/gorilla/csrf/csrf.go
+++ b/vendor/github.com/gorilla/csrf/csrf.go
@@ -89,21 +89,25 @@ type options struct {
// package main
//
// import (
-// "github.com/elithrar/protect"
+// "html/template"
+//
+// "github.com/gorilla/csrf"
// "github.com/gorilla/mux"
// )
//
+// var t = template.Must(template.New("signup_form.tmpl").Parse(form))
+//
// func main() {
-// r := mux.NewRouter()
+// r := mux.NewRouter()
//
-// mux.HandlerFunc("/signup", GetSignupForm)
-// // POST requests without a valid token will return a HTTP 403 Forbidden.
-// mux.HandlerFunc("/signup/post", PostSignupForm)
+// r.HandleFunc("/signup", GetSignupForm)
+// // POST requests without a valid token will return a HTTP 403 Forbidden.
+// r.HandleFunc("/signup/post", PostSignupForm)
//
-// // Add the middleware to your router.
-// http.ListenAndServe(":8000",
-// // Note that the authentication key provided should be 32 bytes
-// // long and persist across application restarts.
+// // Add the middleware to your router.
+// http.ListenAndServe(":8000",
+// // Note that the authentication key provided should be 32 bytes
+// // long and persist across application restarts.
// csrf.Protect([]byte("32-byte-long-auth-key"))(r))
// }
//