]> git.stg.codes - stg.git/blobdiff - projects/stargazer/plugins/configuration/sgconfig/parser.cpp
Added ability to list authorizers for user.
[stg.git] / projects / stargazer / plugins / configuration / sgconfig / parser.cpp
index 8e11a157ccd4a86addebffd3da8f0b49ebfa5ed8..b6c491721f78c53a3c01d5edad0b163cc5ef57f3 100644 (file)
@@ -286,6 +286,13 @@ answerList->push_back(s);
 strprintf(&s, "<CreditExpire value=\"%ld\" />", u->GetProperty().creditExpire.Get());
 answerList->push_back(s);
 
+s = "<AuthorizedBy>";
+std::vector<std::string> list(u->GetAuthorizers());
+for (std::vector<std::string>::const_iterator it = list.begin(); it != list.end(); ++it)
+    s += "<Auth name=\"" + *it + "\">";
+s += "</AuthorizedBy>";
+answerList->push_back(s);
+
 strprintf(&s, "</user>");
 answerList->push_back(s);
 }