Question about possibility of authentication of users on startup

Me and a partner have created a project which uses that are shared with clients using the remote configs feature as well as HWID authentication.
Currently with our HWID authentication as well as adding API keys for each user on the API, we have to do it completely manually which requires connecting to VPS everytime this is needed

Is it possible for us to create and add API keys to the remote sharing as well as add to our current HWID authentication method remotely somehow? As in, being able to create a Discord bot with commands that would allow us to do this remotely? Our current HWID authentication works by checking the users HWID against a set list of HWIDs we have in a list, which seems quite inefficient.

I’m just interested to know whether, we would have to change the source code of openbullet to implement this same type of authentication, but at the start of openbullet or could a custom DLL be used? As well as adding API Keys remotely via a discord bot for example.

Many thanks

I’m not sure I follow. People download a modded client and run it on their PC, and this client connects to your remote OB2 instance and downloads the configs from remote?

If you already changed the code to do this, I suggest you go ahead and also change the code of the server to spawn a discord bot that does exactly this.

You will need to use the Discord.NET library and configure it to start at the beginning of the program (in Startup.cs) and listen to messages. When a specific message with the API key is received, program it to use the OpenBulletSettingsService (obtained by getting the required service through the services builder in Startup.cs) and add the API key to the right place in the settings, then save the settings so the keys are persisted.

Sorry, bad wording on my part.
Currently we are using the base config sharing system with our own HWID lock system in place on each config to prevent sharing of API keys, how ever, when we want to authorize a new user we have to login to our VPS and manually add them to the HWID list as well as make them an API key.

We’ve figured out a way to possibly automate creating API keys via discord bot and our planned solution to HWID would be, when user first authenticates we keep a log of their HWID and keep it in our database, when Openbullet first opens, in the background it downloads a text file with our encrypted HWID’s, this will happenen everytime Openbullet is launched. Then on every config we release we use a read file block to read all the hwids in our ‘database’ and then check if the users HWID would match up.

Im just wondering if this addition to the startup of Openbullet would be possible. Many thanks :slight_smile:

EDIT: this was thought of after my original post, thats why it doesnt match up to what I was saying 100%

The logic of your HWID solution makes sense.

As for the other thing, I am reworking OB2 and adding an API to it, so with just a couple of simple HTTP requests you will be able to add the new API key without logging into the VPS or implementing a discord bot. This is going to take a few months though. So, if you have urgency, I suggest you try to code the discord solution yourself.

Thanks and the OB2 API sounds great :slight_smile: thanks for all the hardwork you’re doing

Also, would you be able to tell me how complete this is at the moment? While my partner and I can do a portion of this, we plan on commissioning other parts of it, so we might as well wait a bit and save some money. Thanks Ruri

The backend is probably going to be done by this month, then I’d say another two months for the frontend, hooking everything up and testing. I did not set a deadline for this so do not count on these estimates, I’d suggest you start implementing your own solution in the meantime.

I’m down to help you with this project please pm me your telegram