:Example: False [False]
:Required: No
+``op-mask``
+
+:Description: The op-mask of the user to be modified.
+:Type: String
+:Example: ``read, write, delete, *``
+:Required: No
+
Response Entities
~~~~~~~~~~~~~~~~~
cout << " --infile=<file> specify a file to read in when setting data\n";
cout << " --categories=<list> comma separated list of categories, used in usage show\n";
cout << " --caps=<caps> list of caps (e.g., \"usage=read, write; user=read\")\n";
+ cout << " --op-mask=<op-mask> permission of user's operations (e.g., \"read, write, delete, *\")\n";
cout << " --yes-i-really-mean-it required for certain operations\n";
cout << " --warnings-only when specified with bucket limit check, list\n";
cout << " only buckets nearing or over the current max\n";
std::string secret_key;
std::string key_type_str;
std::string caps;
+ std::string op_mask_str;
bool gen_key;
bool suspended;
RESTArgs::get_string(s, "key-type", key_type_str, &key_type_str);
RESTArgs::get_bool(s, "system", false, &system);
+ RESTArgs::get_string(s, "op-mask", op_mask_str, &op_mask_str);
if (!s->user->system && system) {
ldout(s->cct, 0) << "cannot set system flag by non-system user" << dendl;
op_state.set_key_type(key_type);
}
+ if (!op_mask_str.empty()) {
+ uint32_t op_mask;
+ if (rgw_parse_op_type_list(op_mask_str, &op_mask) < 0) {
+ ldout(s->cct, 0) << "failed to parse op_mask" << dendl;
+ http_ret = -EINVAL;
+ return;
+ }
+ op_state.set_op_mask(op_mask);
+ }
+
if (s->info.args.exists("suspended"))
op_state.set_suspension(suspended);
--infile=<file> specify a file to read in when setting data
--categories=<list> comma separated list of categories, used in usage show
--caps=<caps> list of caps (e.g., "usage=read, write; user=read")
+ --op-mask=<op-mask> permission of user's operations (e.g., "read, write, delete, *")
--yes-i-really-mean-it required for certain operations
--warnings-only when specified with bucket limit check, list
only buckets nearing or over the current max