On Sunday, September 15, 2013, Andreas Meyer wrote:
> Fabian Kurz <fab...@fkurz.net> wrote:
> > On Sun, Sep 15, 2013 at 08:55:50PM +0200, Andreas Meyer wrote:
> > > I would like to restrict roundcube to one domain and tried the following:
> > >
> > > $rcmail_config['default_host'] = '%d = anup.de';
> > > $rcmail_config['default_host'] = '%n = mail.anup.de';
> >
> > I guess you misunderstood what the replacement variables do.
> > They are set to e. g. %d = hostname ($_SERVER['SERVER_NAME'])
> > so you can just set
>
> yes, I missunderstood that.
>
> >   $rcmail_config['default_host'] = '%d';
> >
> > instead of explicitly setting the host name. The way you do it, the %d
> > will be replaced by the hostname and roundcube will try to connect to
> > "anup.de = anup.de".
>
> yes, but if I set $rcmail_config['default_host'] = '%d'; I can use
> roudncube to login to all other domains dovecot is holding. Every
> entry correct entry I make is ignored. Even with
>
> $rcmail_config['default_host'] = 'ssl://www.foxmailer.de:993';
>
> I can login to every domain.

That's correct. Please understand that Roundcube is just a client
software to access IMAP mailboxes. If the IMAP server allows access,
you get access. $rcmail_config['default_host'] is the configuration
parameter that tells Roundcube which IMAP server to connect to,
nothing more.

There's the $rcmail_config['username_domain'] = ''; config parameter
where you can enter the domain named that is added to username, if
somebody logs in with "anmeyer" instead of the full email address.
This, however, doesn't restrict access if somebody enters the full
email address. In our git repository we now have a new config option
that will allow you to restrict access to the one domain that is
configured in 'username_domain'  even if the IMAP server allows more.
See http://trac.roundcube.net/ticket/1489264 But it isn't yet released
in Roundcube. Use the latest version from git at your own risk.

Regards,
Thomas
_______________________________________________
Roundcube Users mailing list
users@lists.roundcube.net
http://lists.roundcube.net/mailman/listinfo/users

Reply via email to