mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
Basic auth: Fixed issue when using basic auth proxy infront of Grafana, Fixes #1673
This commit is contained in:
parent
cf877e6567
commit
1f330d7753
@ -5,6 +5,7 @@
|
||||
- [Issue #1681](https://github.com/grafana/grafana/issues/1681). MySQL session: fixed problem using mysql as session store
|
||||
- [Issue #1671](https://github.com/grafana/grafana/issues/1671). Data sources: Fixed issue with changing default data source (should not require full page load to take effect, now fixed)
|
||||
- [Issue #1685](https://github.com/grafana/grafana/issues/1685). Search: Dashboard results should be sorted alphabetically
|
||||
- [Issue #1673](https://github.com/grafana/grafana/issues/1673). Basic auth: Fixed issue when using basic auth proxy infront of Grafana
|
||||
|
||||
# 2.0.0-Beta1 (2015-03-30)
|
||||
|
||||
|
@ -28,7 +28,7 @@ func getRequestUserId(c *Context) int64 {
|
||||
func getApiKey(c *Context) string {
|
||||
header := c.Req.Header.Get("Authorization")
|
||||
parts := strings.SplitN(header, " ", 2)
|
||||
if len(parts) == 2 || parts[0] == "Bearer" {
|
||||
if len(parts) == 2 && parts[0] == "Bearer" {
|
||||
key := parts[1]
|
||||
return key
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user