diff --git a/README.md b/README.md index 7757d7b..c57b4f4 100644 --- a/README.md +++ b/README.md @@ -11,7 +11,7 @@ package main import ( "net/http" - "github.com/unrolled/secure" // or "gopkg.in/unrolled/secure.v1" + "github.com/unrolled/secure" ) var myHandler = http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { @@ -153,7 +153,7 @@ import ( "log" "net/http" - "github.com/unrolled/secure" // or "gopkg.in/unrolled/secure.v1" + "github.com/unrolled/secure" ) var myHandler = http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { @@ -186,9 +186,7 @@ The STS header will only be sent on verified HTTPS connections (and when `IsDeve * The `preload` flag is required for domain inclusion in Chrome's [preload](https://hstspreload.appspot.com/) list. ### Content Security Policy -If you need dynamic support for CSP while using Websockets, check out this other middleware [awakenetworks/csp](https://github.com/awakenetworks/csp). - -Otherwise you can use the CSP Builder to create a CSP in a safer way: +You can utilize the CSP Builder to create your policies: ~~~ go import ( @@ -220,7 +218,7 @@ import ( "net/http" "github.com/pressly/chi" - "github.com/unrolled/secure" // or "gopkg.in/unrolled/secure.v1" + "github.com/unrolled/secure" ) func main() { @@ -248,7 +246,7 @@ import ( "net/http" "github.com/labstack/echo" - "github.com/unrolled/secure" // or "gopkg.in/unrolled/secure.v1" + "github.com/unrolled/secure" ) func main() { @@ -273,7 +271,7 @@ package main import ( "github.com/gin-gonic/gin" - "github.com/unrolled/secure" // or "gopkg.in/unrolled/secure.v1" + "github.com/unrolled/secure" ) func main() { @@ -316,7 +314,7 @@ package main import ( "net/http" - "github.com/unrolled/secure" // or "gopkg.in/unrolled/secure.v1" + "github.com/unrolled/secure" "github.com/zenazn/goji" "github.com/zenazn/goji/web" ) @@ -341,7 +339,7 @@ package main import ( "github.com/kataras/iris/v12" - "github.com/unrolled/secure" // or "gopkg.in/unrolled/secure.v1" + "github.com/unrolled/secure" ) func main() { @@ -382,7 +380,7 @@ import ( "net/http" "github.com/gorilla/mux" - "github.com/unrolled/secure" // or "gopkg.in/unrolled/secure.v1" + "github.com/unrolled/secure" ) func main() { @@ -407,7 +405,7 @@ import ( "net/http" "github.com/urfave/negroni" - "github.com/unrolled/secure" // or "gopkg.in/unrolled/secure.v1" + "github.com/unrolled/secure" ) func main() { diff --git a/doc.go b/doc.go index 283deae..371bf0b 100644 --- a/doc.go +++ b/doc.go @@ -6,7 +6,7 @@ Package secure is an HTTP middleware for Go that facilitates some quick security import ( "net/http" - "github.com/unrolled/secure" // or "gopkg.in/unrolled/secure.v1" + "github.com/unrolled/secure" ) var myHandler = http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {