Hi!
Today I asked my gamehost Multiplay to please update some of their addons since they are outdated.
First I got an answer that this could take some time because of the multiple patches and that she would come back to me. Now 9 hours later I contacted them again and asked, then I got the quoted answer below:
Is there really a potentially massive security risk by allowing csharp addons instead of .lua?
If so this is a gamebreaker for people hosting modded servers on Multiplay servers.
Solved Security of new .cs plugins
Discussion in 'Rust Discussion' started by XperienC, Feb 10, 2015.
-
Wulf Community Admin
They haven't provided any evidence of there being any security risks, but we're more than willing to fix any actual issues if they can provide evidence of such. CSharp plugins are sandboxed just as Lua and the other plugin languages are. If anything, they are even more secure than Lua was in the past.
Every currently supported plugin language extension has their own sandbox system. Each currently has a whitelist or blacklist that prevents usage of potentially malicious code. We've tried to cover out bases with it, blacklisting or whitelisting as much of the ones we can think of and find that could be used wrongly.
https://github.com/OxideMod/Oxide/blob/master/Oxide.Ext.CSharp/CompilablePlugin.cs#L31
https://github.com/OxideMod/Oxide/blob/master/Oxide.Ext.JavaScript/JavaScriptExtension.cs#L56
https://github.com/OxideMod/Oxide/blob/master/Oxide.Ext.Lua/LuaExtension.cs#L45
https://github.com/OxideMod/Oxide/blob/master/Oxide.Ext.Python/PythonExtension.cs#L54
There is even a sandbox for the configuration files, chrooting to the Oxide root directory.
https://github.com/OxideMod/Oxide/commit/9d57932e4590dfb25b583f99c25cda201ed5f61f
@bawNg also made a good point as well regarding C# plugins:
-
We are indeed in the process of reviewing supporting the new types of plugins.
As I'm sure everyone will appreciate we don't want your servers going offline for extended periods due to potentially malicious plugins so we wanted to perform due diligence on the functionality before allowing their install. -
read what sandboxie does, then you'll realise your safe
-
With C# it could well be its possible to bypass that, we need to validate the hypothesis though hence the DD.
Last edited by a moderator: Feb 13, 2015 -
true but as far as i know its all vritual meaning its safe from accessing hosts operating system, you could simply have one dedicated server testing it and allow your customers at there own risk use c# but migrate to another dedicated server for testing purpose
-
Wulf Community Admin
-
im talking about oxide being sandboxie
-
What multiplay are afraid is that one person uses the plugins to fuck an entire server as they are probably using shared machines.
So with 1 malicious plugin they are scared to fuck 30 other customers.
But again ... Can't éven use (lock) in c# xD -
This ^^
-
But only 1 thing i dont get is that all plugins are the ones posted on this forum, you only have à couple personnal plugins there, why not only accept plugins posted on oxide?
-
Who is legally responsible for reviewing those to ensure they aren't malicious?
-
Edit:
As far as i know oxide hasn't any api like "Bukkit" with its "BukGet" to install all plugins from their site, or am i wrong?Last edited by a moderator: Feb 13, 2015 -
Légally no one, but wulf goes around every plugins to make sûre they arent malicious.
Someone posted à:
using System.IO;
And we all looked into it to make sûre he wasnt doing something malicious,
But as it's sandboxed, that person can add : using System.IO but he can't use it as it's blacklisted from oxide. -
just to clarify, nobody can hook something outside oxide to for example damage the system ? Like deleting folders etc. pp. ?
I guess every hosts nightmare is when someone can upload their own .cs - Oxide plugin and with this plugin damaging the whole server, like deleting every customer folder or even changing the password or making the server unbootable. -
Wulf Community Admin
-
well if you let anyone edit oxide .dll files yes they can do anything ... but again they could install anything.
as long as you don't let players edit the .dlls there can't (shouldnt or what ever XD) be any bad surprises. -
-