ID:293289
 
Is there a way to ban a user using DreamDaemon on Linux without a GUI?

I'm trying to ban users on a remote server without a GUI.
G'day Reikoshea.

There is a way to do it, but it's not a very easy thing to do, and I'm quite unsure how to do it myself.

From memory: DreamDaemon will create a text file in your cfg folder to handle all its bans. You'd have to copy this text file from your computer over to the Linux server.

The only problem is, you then have to reboot the Linux server.

I don't know of any other methods to ban someone using the DreamDaemon on Linux. Someone else might be able to fill in the blanks (the text file name for instance, it'll probably stand out like a sore thumb though), but that'll give you a head-start on what to expect.

Thanks Much.
Tiberath
In response to Tiberath
So i can get the ban file my developer has on his machine and the HUP the daemon.

Sounds like a plan. Ill look at it tonight.
In response to Reikoshea
Well, I just took a quick look at it, since I got a code update yesterday to help fix this issue. There is a Banned.sav file in byond/MyWorld/world/Names/Banned.sav

Unfortunately its binary. Is there no way to add users to this file to prevent us from having to give a back door to admins. That way my dev can just submit a list of users to me to ban every day.
In response to Reikoshea
Although fantastically not documented, Linux BYOND will source two files for bans. These files are ${HOME}/.byond/cfg/keyban.txt and ${HOME}/.byond/cfg/ipban.txt respectively.

keyban.txt takes a list of ckeys to ban, one per line (The -- just denote the start and end of the file, they aren't included):

keyban.txt:
---------------------------------------
stephen001
reikoshea
---------------------------------------

ipban.txt accepts a list of IP addresses, one per line:

ipban.txt:
---------------------------------------
87.123.34.231
120.109.34.250
---------------------------------------

It is important to ensure that in ipban.txt, there are no empty lines, as this used to (I suspect it still does) end up IP banning the full IP range, that is ... everyone.

Another note, ${HOME} will be the home directory of the user DreamDaemon is run on. Just incase you run with a different user to your regular user account.