[External App] MIAB Account Management

Over the past couple weeks, @alento and myself have been working on a script to allow non-admins to manage a domain (example: a company running MIAB can give an HR department access to my script to add or remove users, without the need to give them full access to the MIAB instance). It does not use a traditional database, it uses a custom flat-file database that I have designed myself over the years. So the script can be drag and drop, however the config.php should be properly configured for maximum security.

The GitHub page is located here: https://github.com/mitchellurgero/miab_account_management

The setup is simple:

  1. git clone the repository to a webservers root directory (for Apache / Nginx the default is /var/www/html
  2. copy config.example.php to config.php. Modify this to your config.
  3. The db_location variable should not be anywhere inside, or under the webserver’s root. If you are using a default root, a good play is just /var/www. However anywhere is good as long as the webserver has read/write access.

Some screen shots:


This is a neat idea, would be very handy for someone who manages multiple domains and users. :+1:

1 Like

In my use case … I have a domain which is being serviced by one of my MiaB instances and the owner of this domain demands the ability to add and delete mailboxes himself. This solves that issue without giving away access to the entire box. :slight_smile:

Thanks again @murgero for this script - and dealing with my little fixes. :stuck_out_tongue:

1 Like

I love programming and writing php scripts so it was fun to do! I hope more people find it helpful :slight_smile:

1 Like

Hi everyone,

I just installed fresh droplet and cloned the script. However, it didn’t work for me.

Can you please provide the online demo, that you found working for you ?

How are you installing? make sure to edit config.php properly.

Very cool dude! I love your latest commit *shifty eyes*

I had started something like this a little while ago in Python but didn’t get very far.

I would suggest that the basic email setup info has a place on here too (I didn’t see it after a quick read through the code). And maybe even a link which opens up webmail. Perhaps I’ll try this out and submit a PR at the end of the month.

Do you think if something like this is hosted on the box, it would be possible to use the existing email account password?

1 Like

You can sign in as any registered account (make sure to have a proper and secure path for the flat file db in config.php!) Just configure admin credentials in config.php and go. It can be on any server with PHP7 (should work on PHP5.X as well, but NOT TESTED OR SUPPORTED!)

This kinda goes outside the scope of this webapp. The web app is purely for admins to allow their end users (example: customers, managers, HR, etc etc) to manage email accounts. If you submit a PR and it looks clean and falls in line with my code, I’ll accept it. But otherwise I will not do it myself. But thank you for the suggestion!