Adds the alternative use of password, instead of admin token,
to validate tokens.
Signed-off-by: Christophe Courtaut <christophe.courtaut@gmail.com>
}
if (url[url.size() - 1] != '/')
url.append("/");
+ std::string admin_token;
+ if (get_keystone_admin_token(admin_token) < 0)
+ return -EINVAL;
+ if (get_keystone_url(url) < 0)
+ return -EINVAL;
+
url.append("v2.0/tokens/");
url.append(token);
- validate.append_header("X-Auth-Token", g_conf->rgw_keystone_admin_token);
+ validate.append_header("X-Auth-Token", admin_token);
int ret = validate.process(url.c_str());
if (ret < 0)