question about user types

General eFa discussion
Post Reply
ovizii
Posts: 463
Joined: 11 May 2016 08:08

question about user types

Post by ovizii »

I previously had only listed one user per domain as domain administrator, it looked like this:

https://monosnap.com/file/TMty0szOLSMhT ... F11tILsmiE

you notice the user name is the full domain. Seems that is no longer possible as I now get: "For all users other than Administrator you must use an e-mail address for the username"

any quick way to set defaults up for a domain without manually creating each and every user?
ovizii
Posts: 463
Joined: 11 May 2016 08:08

Re: question about user types

Post by ovizii »

Found this manual entry: https://docs.mailwatch.org/using/user-filter.html

is that how it works now? Should I rename my domain admin users?
henk
Posts: 517
Joined: 14 Dec 2015 22:16
Location: Netherlands
Contact:

Re: question about user types

Post by henk »

Not sure if you mean this: viewtopic.php?t=3002
It's not recommended, but it works fine with me.

/var/www/html/mailscanner/conf.php

Code: Select all

//Allow domain admins to create/edit/delete other domain admins from the same domain (not recommended, only for backward compatibility)
define('ENABLE_SUPER_DOMAIN_ADMINS',true);
//Allow the username of domain admins and normal users to not be in mail format (not recommended, only for backward compatibility)
define('ALLOW_NO_USER_DOMAIN',true);
“We are stuck with technology when what we really want is just stuff that works.” -Douglas Adams
ovizii
Posts: 463
Joined: 11 May 2016 08:08

Re: question about user types

Post by ovizii »

Yes, thanks henk, that is exactly what I meant but the link you posted is a bit confusing as the screenshot does not exactly fit the text you wrote there.

This is what I am confused about:
In previous MailWatch versions we could enter any username in a non valid email format, to generate 1 single quarantine report for all mail-users for a specific domain.
as far as I remember, if I simply entered a domain as username and added an email to that user, that email would receive a quarantine report for that whole domain.

Now if I look at your screenshot, the username is a full email address meaning that user will only receive a quarantine report for that particular email, or am I wrogn here? Shouldn't the username be: @localhost and the recipient email monitor@localhost?
henk
Posts: 517
Joined: 14 Dec 2015 22:16
Location: Netherlands
Contact:

Re: question about user types

Post by henk »

as far as I remember, if I simply entered a domain as username and added an email to that user, that email would receive a quarantine report for that whole domain.
You did remember well :D

As I use fetchmail to fetch mail form external sources, I map that to a local user. So every mail user has a user@localhost account on EFA. ( also dovecot is running ). The the recipient email is an admin user at my domain (my internal mailserver)

Just succesfull tested the domain only username: localhost
2019-05-14-User Management.png
2019-05-14-User Management.png (15.42 KiB) Viewed 14023 times
Result:

Code: Select all

/usr/local/bin/mailwatch/tools/Cron_jobs/mailwatch_quarantine_report.php

 === Generating report for localhost type=D
 ==== Recipient e-mail address is test@mydomain.com
 ==== Building list for localhost
 ==== Found 4 quarantined e-mails

 ==== Sent e-mail to test@mydomain.com

 === Generating report for monitor@localhost type=D
 ==== Recipient e-mail address is test@mydomain.com
 ==== Building list for localhost
 ==== Found 4 quarantined e-mails

 ==== Sent e-mail to test@mydomain.com
“We are stuck with technology when what we really want is just stuff that works.” -Douglas Adams
ovizii
Posts: 463
Joined: 11 May 2016 08:08

Re: question about user types

Post by ovizii »

Thanks for confirming and digging out that old post. I did not have to add a new user in a while but when I tried adding 2 new domains and saw that all my old users were in a different format, I just vaguely remembered there was a reason for that but couldn't find where it was described :-)

I'll get to editing my config today so that I can keep using this old username format.
Gogo
Posts: 3
Joined: 24 May 2019 11:38

Re: question about user types

Post by Gogo »

I tried to follow that link but I'm not understanding the whole concept. Can anyone help out on this?
ovizii
Posts: 463
Joined: 11 May 2016 08:08

Re: question about user types

Post by ovizii »

I can try and explain how I understand the situation but I might be wrong.

Looking at https://docs.mailwatch.org/using/user-filter.html and viewtopic.php?t=3002

this is what I took away:
  • If you create a user named johndoe@example.com as user type User and I log-in as that user, I will only be able to see e-mail address to/from me and to be able to add Blacklist/Whitelist entries for my address (if enabled).
  • If you create a user named domain-admin@example.com as type Domain Administrator and I log-in as that user, I will only be able to see messages to/from my domain or create blacklist/whitelist entries for the entire domain or for a specific user. The domain in the mail address (part after @) will be used to identify the users domain. If username is not in format of a mail address this assumes the domain “no domain” and the domain admin will only be able to edit/see users that also have “no domain”.
  • The Administrator type can do anything for any user or domain.
If you enable this option:
define('ALLOW_NO_USER_DOMAIN',true);

you can also use example.com as username and assign this user the domain admin role.
annabellelee
Posts: 1
Joined: 28 Jun 2019 09:13
Contact:

Re: question about user types

Post by annabellelee »

Thank you for the information.
Post Reply