Add bots to uhub-passwd

This commit is contained in:
klondike 2014-04-04 05:01:07 +02:00 committed by Francisco Blas (klondike) Izquierdo Riera
parent d86ef503b3
commit 7bda215ad4

View File

@ -101,7 +101,19 @@ static const char* validate_cred(const char* cred_str)
if (!strcmp(cred_str, "user"))
return "user";
fprintf(stderr, "Invalid user credentials. Must be one of: 'admin', 'super', 'op' or 'user'\n");
if (!strcmp(cred_str, "bot"))
return "bot";
if (!strcmp(cred_str, "ubot"))
return "ubot";
if (!strcmp(cred_str, "opbot"))
return "opbot";
if (!strcmp(cred_str, "opubot"))
return "opubot";
fprintf(stderr, "Invalid user credentials. Must be one of: 'bot', 'ubot', 'opbot', 'opubot', 'admin', 'super', 'op' or 'user'\n");
exit(1);
}