fix: change session cookie name used by UI to avoid conflict with incompatible 2.0.x cookie (#22632)

pull/22639/head
Daniel Moran 2021-10-07 15:53:55 -04:00 committed by GitHub
parent a02782c63f
commit e12e78aa69
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View File

@ -161,7 +161,7 @@ func decodeSignoutRequest(ctx context.Context, r *http.Request) (*signoutRequest
}, nil
}
const cookieSessionName = "session"
const cookieSessionName = "influxdb-oss-session"
func encodeCookieSession(w http.ResponseWriter, s *influxdb.Session) {
c := &http.Cookie{

View File

@ -58,7 +58,7 @@ func TestSessionHandler_handleSignin(t *testing.T) {
password: "supersecret",
},
wants: wants{
cookie: "session=abc123xyz; Path=/api/",
cookie: "influxdb-oss-session=abc123xyz; Path=/api/",
code: http.StatusNoContent,
},
},