• If you need help or want to discuss things, you now can also join us on our Discord Server!
  • A first preview of the unlimited version of SinusBot can be found in the Upcoming Changes thread. A version for Windows will follow, but we don't have a release date, yet.

Feature Execute External Program via API

Status
Not open for further replies.

Tuetchen

Diesmon Dominator
is awesome!
Contributor
Insider
Currently the Scripting Engine can be quite restricting.
Instead of adding everything to the engine it would be nice to have the option to execute external applications via the engine and maybe be able to do something with its output.
This would allow us to bypass these missing features in an easier way.

Of course it could be a security problem but still the user would need to give the script the permissions to execute something first like in other "problematic" libs
 
Last edited:

Tuetchen

Diesmon Dominator
is awesome!
Contributor
Insider
Well we allow networking stuff which can be way more insecure than running a program the user has to install first.. so yeah..
 

irgendwr

no longer active, "retired" staff member
is awesome!
V.I.P.
is uber awesome!
Contributor
Insider
a program the user has to install first
"just running a programm" is basically running a command (as they are just programs)

Which of the following are you comfortable with:
(potentially) giving remote access to a shell of your server
or running a script that has to be manually approved and can make http calls with rate limits? :D
so yeah..
 

Tuetchen

Diesmon Dominator
is awesome!
Contributor
Insider
1. Its way more than just http calls^^
2. To Be honest - with neither if i dont know the script and thats why we currently need to manually give a script permissions first to use the 'net' class
 

irgendwr

no longer active, "retired" staff member
is awesome!
V.I.P.
is uber awesome!
Contributor
Insider
Its way more than just http calls^^
then provide more examples
thats why we currently need to manually give a script permissions first to use the 'net' class
yup, so that's mostly safe then

Btw: the api is not the same as the scripting engine, if you mean the engine it makes a bit more sense, otherwise It's really like giving people access to a shell on your server over http.

But even if you would have to manually allow this feature (like the net class) I would still fear command injections (e.g. if a parameter is not escaped correctly), privilege escalations and so on.

Edit: + in the last post you admitted that you wouldn't be comfortable with this yourself! :D
And just to be safe: I don't have anything against you, I just like to argue about this xD
 
Last edited:

Tuetchen

Diesmon Dominator
is awesome!
Contributor
Insider
the api is not the same as the scripting engine, if you mean the engine it makes a bit more sense

Eh yeah scripting engine to be honest I didnt even know there is a http api just saw that sry.

yup, so that's mostly safe then xD

Im not saying that this is totally save either but thats the current state the net class is accessible.
 
Last edited:

irgendwr

no longer active, "retired" staff member
is awesome!
V.I.P.
is uber awesome!
Contributor
Insider
Im not saying that this is totally save either but thats the current state the net class is implemented.
Yeah I know, that was my honest opinion. I think the way the net class is implemented is pretty safe.
 

Tuetchen

Diesmon Dominator
is awesome!
Contributor
Insider
Yeah sure still the user should not blindly give every script the permissions to those classes.

I mean we have a permission system: why not using it; Its still the users decision if he wants to use it on his own risk or not. And well ... its javascript - if its a problematic permission the user can still check the sourcecode and decide afterwards if he want to give the script the specific permission.
 

irgendwr

no longer active, "retired" staff member
is awesome!
V.I.P.
is uber awesome!
Contributor
Insider
Its still the users decision if he wants to use it on his own risk or not. And well ... its javascript - if its a problematic permission the user can still check the sourcecode and decide afterwards if he want to give the script the specific permission.
Yes, but something like unsafe escaping could easily be overlooked.
And some people even run the bot as root!

Ok I think that's enough posts for me today, good night xD
 
Last edited:
Status
Not open for further replies.
Top