Documentation ¶
Overview ¶
Copyright 2022 Sorint.lab
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied See the License for the specific language governing permissions and limitations under the License.
Index ¶
- func NewAuthChecker(log zerolog.Logger, configstoreClient *csclient.Client, ...) func(http.Handler) http.Handler
- func NewMaxBytesHandler(h http.Handler, n int64) *maxBytesHandler
- func NewSetCSRFHeader(log zerolog.Logger) func(http.Handler) http.Handler
- func NewSkipCSRFOnTokenAuth(log zerolog.Logger) func(http.Handler) http.Handler
- func NewWebBundleHandlerFunc(gatewayURL string) func(w http.ResponseWriter, r *http.Request)
- type AuthChecker
- type AuthCheckerOption
- type SetCSRFHeader
- type SkipCSRFOnTokenAuth
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewAuthChecker ¶ added in v0.8.0
func NewMaxBytesHandler ¶
func NewSetCSRFHeader ¶ added in v0.8.0
func NewSkipCSRFOnTokenAuth ¶ added in v0.8.0
func NewWebBundleHandlerFunc ¶
func NewWebBundleHandlerFunc(gatewayURL string) func(w http.ResponseWriter, r *http.Request)
Types ¶
type AuthChecker ¶ added in v0.8.0
type AuthChecker struct {
// contains filtered or unexported fields
}
func (*AuthChecker) ServeHTTP ¶ added in v0.8.0
func (h *AuthChecker) ServeHTTP(w http.ResponseWriter, r *http.Request)
type AuthCheckerOption ¶ added in v0.8.0
type AuthCheckerOption func(*AuthChecker)
func WithCookieChecker ¶ added in v0.8.0
func WithCookieChecker(sc *scommon.CookieSigningData, unsecureCookies bool) AuthCheckerOption
func WithRequired ¶ added in v0.8.0
func WithRequired(required bool) AuthCheckerOption
func WithTokenChecker ¶ added in v0.8.0
func WithTokenChecker(adminToken string) AuthCheckerOption
type SetCSRFHeader ¶ added in v0.8.0
type SetCSRFHeader struct {
// contains filtered or unexported fields
}
func (*SetCSRFHeader) ServeHTTP ¶ added in v0.8.0
func (h *SetCSRFHeader) ServeHTTP(w http.ResponseWriter, r *http.Request)
type SkipCSRFOnTokenAuth ¶ added in v0.8.0
type SkipCSRFOnTokenAuth struct {
// contains filtered or unexported fields
}
func (*SkipCSRFOnTokenAuth) ServeHTTP ¶ added in v0.8.0
func (h *SkipCSRFOnTokenAuth) ServeHTTP(w http.ResponseWriter, r *http.Request)
Click to show internal directories.
Click to hide internal directories.