upstream asis
This commit is contained in:
3
auth.go
3
auth.go
@@ -20,7 +20,8 @@ func handleAuth(c *gin.Context) error {
|
||||
|
||||
authorization = strings.Trim(authorization[len("Bearer"):], " ")
|
||||
log.Println("Received authorization", authorization)
|
||||
if authorization != authConfig.Value {
|
||||
|
||||
if authConfig.Value != "asis" && authorization != authConfig.Value {
|
||||
err = errors.New("wrong authorization header")
|
||||
c.AbortWithError(403, err)
|
||||
return err
|
||||
|
||||
Reference in New Issue
Block a user