summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar Jeffrey Hutzelman <jhutz@cmu.edu>2013-02-22 20:41:55 -0500
committerGravatar Karl Ramm <kcr@1ts.org>2013-02-26 23:01:10 -0500
commit58a713e13c61dd4ce0b7f9f81685879353c0b911 (patch)
treea64db1d471e16a5240325dd349f3c0d9274c91c7
parentd2b1791a3b05d3ed0b03dcb87c6ea729a99f0ceb (diff)
Allow opstaff to submit location updates for users
This allows anyone on opstaff.acl to submit location updates, including flushing all locations, for a user other than themselves. This is the server side of #102
-rw-r--r--server/uloc.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/server/uloc.c b/server/uloc.c
index 000a7c6..6b26894 100644
--- a/server/uloc.c
+++ b/server/uloc.c
@@ -168,7 +168,8 @@ ulogin_dispatch(ZNotice_t *notice,
return ZERR_NONE;
}
if (!bdumping &&
- (!auth || strcmp(notice->z_sender, notice->z_class_inst) != 0)) {
+ (!auth || strcmp(notice->z_sender, notice->z_class_inst) != 0) &&
+ (!auth || !opstaff_check(notice->z_sender))) {
zdbug((LOG_DEBUG,"unauthentic ulogin: %d %s %s", auth,
notice->z_sender, notice->z_class_inst));
if (server == me_server)