sink_writes(ev_writer_sink(c->w), "510 Prohibited\n");
return 1;
}
- if(mixer_control(&l, &r, set))
+ if(mixer_control(-1/*as configured*/, &l, &r, set))
sink_writes(ev_writer_sink(c->w), "550 error accessing mixer\n");
else {
sink_printf(ev_writer_sink(c->w), "252 %d %d\n", l, r);
int nvec) {
const char *rights;
+ if(!config->remote_userman && !(c->rights & RIGHT__LOCAL)) {
+ sink_writes(ev_writer_sink(c->w), "550 Remote user management is disabled\n");
+ return 1;
+ }
if(nvec > 2) {
rights = vec[2];
if(parse_rights(vec[2], 0, 1)) {
int attribute((unused)) nvec) {
struct conn *d;
+ if(!config->remote_userman && !(c->rights & RIGHT__LOCAL)) {
+ sink_writes(ev_writer_sink(c->w), "550 Remote user management is disabled\n");
+ return 1;
+ }
if(trackdb_deluser(vec[0])) {
sink_writes(ev_writer_sink(c->w), "550 Cannot delete user\n");
return 1;
int attribute((unused)) nvec) {
struct conn *d;
+ if(!config->remote_userman && !(c->rights & RIGHT__LOCAL)) {
+ sink_writes(ev_writer_sink(c->w), "550 Remote user management is disabled\n");
+ return 1;
+ }
/* RIGHT_ADMIN can do anything; otherwise you can only set your own email
* address and password. */
if((c->rights & RIGHT_ADMIN)
struct kvp *k;
const char *value;
+ if(!config->remote_userman && !(c->rights & RIGHT__LOCAL)) {
+ sink_writes(ev_writer_sink(c->w), "550 Remote user management is disabled\n");
+ return 1;
+ }
/* RIGHT_ADMIN allows anything; otherwise you can only get your own email
- * address and righst list. */
+ * address and rights list. */
if((c->rights & RIGHT_ADMIN)
|| (!strcmp(c->who, vec[0])
&& (!strcmp(vec[1], "email")