bugsnag-go: github.com/bugsnag/bugsnag-go/examples/revelapp/app Index | Files | Directories

package app

import "github.com/bugsnag/bugsnag-go/examples/revelapp/app"

Index

Package Files

init.go

Variables

var (
    // AppVersion revel app version (ldflags)
    AppVersion string

    // BuildTime revel app build-time (ldflags)
    BuildTime string
)
var HeaderFilter = func(c *revel.Controller, fc []revel.Filter) {
    c.Response.Out.Header().Add("X-Frame-Options", "SAMEORIGIN")
    c.Response.Out.Header().Add("X-XSS-Protection", "1; mode=block")
    c.Response.Out.Header().Add("X-Content-Type-Options", "nosniff")
    c.Response.Out.Header().Add("Referrer-Policy", "strict-origin-when-cross-origin")

    fc[0](c, fc[1:])
}

HeaderFilter adds common security headers There is a full implementation of a CSRF filter in https://github.com/revel/modules/tree/master/csrf

Directories

PathSynopsis
controllers

Package app imports 2 packages (graph). Updated 2019-01-13. Refresh now. Tools for package owners. This is an inactive package (no imports and no commits in at least two years).