commit 2565c02406e3121608633eb50fb75c03b617ca43 from: Tracey Emery date: Sat Jul 18 00:34:18 2020 UTC fix show/list things for non-root user commit - eac7a4237ef12ce112175e5eb9ba4679a19853ca commit + 2565c02406e3121608633eb50fb75c03b617ca43 blob - 97f97b38314f41b86205e14f26763efd3fbbe3bf blob + 72849ec34061d0765726769b9718deae9105a785 --- thingsctl/thingsctl.c +++ thingsctl/thingsctl.c @@ -158,8 +158,8 @@ main(int argc, char *argv[]) 0, -1, NULL, 0); break; case SHOW_PACKETS: - imsg_compose(ibuf, IMSG_GET_INFO_PARENT_REQUEST, 0, - 0, -1, NULL, 0); + /* imsg_compose(ibuf, IMSG_GET_INFO_PARENT_REQUEST, 0, */ + /* 0, -1, NULL, 0); */ break; case SHOW_PARENT: imsg_compose(ibuf, IMSG_GET_INFO_PARENT_REQUEST, 0, blob - 925616b8d926051dcffd040c01144be549cde31f blob + ed3b4fd458588303b1670eb16e0b97ef9fa255e7 --- thingsd/thingsd.c +++ thingsd/thingsd.c @@ -99,6 +99,7 @@ thingsd_dispatch_control(int fd, struct privsep_proc * case IMSG_GET_INFO_SOCKETS_REQUEST: sockets_show_info(ps, imsg); break; + case IMSG_GET_INFO_THINGS_REQUEST: case IMSG_GET_INFO_THINGS_REQUEST_ROOT: things_show_info(ps, imsg); break; @@ -140,25 +141,8 @@ thingsd_dispatch_things(int fd, struct privsep_proc *p { struct privsep *ps = p->p_ps; + log_info("%s", __func__); switch (imsg->hdr.type) { - case IMSG_GET_INFO_CLIENTS_DATA: - proc_forward_imsg(ps, imsg, PROC_CONTROL, -1); - break; - case IMSG_GET_INFO_CLIENTS_END_DATA: - proc_forward_imsg(ps, imsg, PROC_CONTROL, -1); - break; - case IMSG_GET_INFO_SOCKETS_DATA: - proc_forward_imsg(ps, imsg, PROC_CONTROL, -1); - break; - case IMSG_GET_INFO_SOCKETS_END_DATA: - proc_forward_imsg(ps, imsg, PROC_CONTROL, -1); - break; - case IMSG_GET_INFO_THINGS_DATA: - proc_forward_imsg(ps, imsg, PROC_CONTROL, -1); - break; - case IMSG_GET_INFO_THINGS_END_DATA: - proc_forward_imsg(ps, imsg, PROC_CONTROL, -1); - break; case IMSG_ADD_THING: proc_forward_imsg(ps, imsg, PROC_CONTROL, -1); break;