-
Notifications
You must be signed in to change notification settings - Fork 237
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unable to apply #196
Comments
https://docs.oracle.com/cd/E19253-01/817-0403/sysrescron-23/index.html UPDATE: It only seems to solve to problem to reload the config via cli. Probably @tiredofit has any idea wich user must have permission in order to solve the problem for the ui |
Thanks @bsteimer |
Noticed that next time I had a similiar problem, also with the cli command: This seems to resolve my problem this time: |
Hi, After all, I used the official ISO, because there is lot of limitation in manual or docker install of freepbx/asterisk. But after install iso version, I have issue with others things ! lol Thanks |
I'm on 15-5.1.1 - realised 15-5.2.0 is now available - will see if it happens there too. problem seems to be busybox, but I really don't want to make /bin/busybox suid lrwxrwxrwx 1 root root 12 Feb 15 18:46 /usr/sbin/crontab -> /bin/busybox
[tiredofit/debian:7.3.5 02:37:37] # ls -l /bin/busybox
-rwxr-xr-x 1 root root 1945856 Apr 1 2019 /bin/busybox
[tiredofit/debian:7.3.5 02:38:01] # su - asterisk
asterisk@a9f43e178b2b:~$ crontab
crontab: must be suid to work properly
asterisk@a9f43e178b2b:~$ crontab -e -u asterisk
crontab: must be suid to work properly Outside the container in my normal host:
Just for kicks, I tried - can't be done:
|
@jeffgoh You were so close! Notice that you're trying to run the |
You're right - not sure how I missed that. I can confirm that making /bin/busybox setuid allows you to do update via GUI - but that's gotta be a massive security hole. Will go think how to fix this properly, but it's an adequate workaround if your FreePBX instance (both http and SIP) has no exposure to the Internet, I guess. |
I went thru a few different images.
15-5.0.7 has a standalone binary for crontab which is setgid to crontab, which works:
15-5.2.0 and 15-5.1.1 have the softlink to /bin/busybox,which doesn't allow the GUI to apply updates:
|
My workaround was:
#!/bin/bash
# Workaround: https://github.com/tiredofit/docker-freepbx/issues/196#issuecomment-1337997584
chmod u+s /bin/busybox
chmod +x ./volumes/freepbx/scripts/update-suid.sh During the initialization, you should see this entries in your log output:
|
You could also create a small
|
Not sure, whether this tip here: https://unix.stackexchange.com/questions/279223/how-do-i-set-up-busybox-to-allow-a-non-root-user-to-set-the-date#279230 works with the busybox in the docker image to help to further restrict the required setuid to 'crontab' only. Yet worth giving it a try... |
This bug was introduced for first time since this commit on the parent image tiredofit/docker-debian: According to the cron applet's documentation:
So, nothing should be wrong for setting up the suid permission. My thoughts:
|
Looks like there has been some good problem solving here.
I'm doing the bare minimum on this image for maintenance as I haven't used it in production since 2018, so I appreciate the sleuthing to find out where things have gone wrong. I'm willing to put a patch to make this start saving configuration again, but not much more unless I have better incentives. There are a few options: 1 - I get a working build of 2 - You could investigate the /etc/busybox.conf file that talks about providing poormans SUID to specific applications - This seems the most logical without too much bending.
3 - Busybox could be compiled from source (twice), 1st package with everything BUT 4 - The base image could be refactored as BeardOverflow (nice username btw, elicited a morning grin) stated to add a new type of cron management via the functionality I built into the base images.. This at this time I'd leave to the community or would need to be commissioned this type of feature addon. I'm heading away for a break for a week and will see the responses upon return. |
Summary
Unable to apply on GUI
Steps to reproduce
Just apply config
Relevant logs and/or screenshots
Environment
For testing, I set to 777 all mounted directory:
same error.
Help! 🆘
The text was updated successfully, but these errors were encountered: