how to avoid using this flag, I was successful in ...
# general
m
how to avoid using this flag, I was successful in turning osqueryd to xyz_daemon and now I have to use 
--allow_unsafe
 to add my daemon to the fleetDM server, I am looking forward to avoid this issue and solve it.
a
The first step is to double check the osquery permissions
ideally both the binary and the folder that contains it are set to not be writable (except for root)
So you can start with: Owner: chown root:root osquery Permissions: chmod 755 osquery
m
tried this but still I get the unsafe permissions error.
m
a
I didn't notice this at first; are you trying to rename the binary? This won't work due to several reasons in the code and is not supported
m
Yea that's been his focus for a while https://github.com/osquery/osquery/issues/7265 but now the question is why this might affect "unsafeness"
m
Ok, so what i did was to rename osqueryd to xyz_daemon what i did was found and replaced the osqueryd in all files to xyz_daemon and it worked but now that affects the safeness
a
@Madhur Jodhwani do note that this affects licensing, since you are changing existing code that is both under GPL and Apache. Users of osquery can decide to use either license and can request the full source code
m
oh
so,what should I do?
a
Use the standard osquery daemon, or include a new notice in your distribution stating that 1. it is no longer an official copy of osquery 2. it is a custom fork 3. where to find the source code for your fork
While you can choose either GPL or Apache for your own machine and personal use, you can't take away the right for other users that are running your binary to pick the license they want to use between the two
m
No, I am not distributing it for the time being but using it only for my personal use, so still I should be following any guidelines?
a
If it is for your personal use, I don't think (but big disclaimer for everything I said about licensing: i am not a lawyer)
m
ok, thanks
but how do I avoid the --allow_unsafe flag part? I really need to get it off.
a
I am not sure, since it's a modified binary you may have to debug the code
it's not a version we support
m
ok, but where should i look?
since for normal osqueryd also it shows the same error
m