File tree Expand file tree Collapse file tree 1 file changed +3
-5
lines changed Expand file tree Collapse file tree 1 file changed +3
-5
lines changed Original file line number Diff line number Diff line change @@ -117,12 +117,8 @@ void validationHandler(
117117{
118118 std::string username;
119119
120- // validate that the secret matches what we expect
121- std::string secret =
122- pConnection->request ().headerValue (kServerRpcSecretHeader );
123-
124120 // if there is no secret, check for a message signature instead
125- if (secret. empty ( ))
121+ if (!pConnection-> request (). containsHeader ( kServerRpcSecretHeader ))
126122 {
127123 if (!validateSecureCookie (pConnection, &username, fallbackAllowed))
128124 {
@@ -134,6 +130,8 @@ void validationHandler(
134130 else
135131 {
136132 // used for traditional unix socket mode
133+ // validate that the secret matches what we expect
134+ std::string secret = pConnection->request ().headerValue (kServerRpcSecretHeader );
137135 if (secret != s_sessionSharedSecret)
138136 {
139137 if (!fallbackAllowed)
You can’t perform that action at this time.
0 commit comments