[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: pop3d virtual domains
From: |
Alain Magloire |
Subject: |
Re: pop3d virtual domains |
Date: |
Thu, 30 Aug 2001 21:56:54 -0400 (EDT) |
Bonjour
> > > Other servers I've seen supporting "virtual domains" allow the same
> > > options. I think @ is the most aesthetic, but breaks in many mail
>
> For example, some "smart" clients crop out the hostname to use as the
> server name.
>
> > should not we make it possible to detect this?
> > Meaning the virtual support for ftpd. for example, will
> > call getsockname () and base on the IP/DNS choose the virtual domain
> > for the user.
>
> But this only works when you have one IP for each virtual domain.
Yes, agreed.
I was thinking that it would not be hard to do, in regard of the
current code introduce by Jakob and Sergey.
static struct passwd *
pop3d_ip_virtual (const char *u)
{
struct passwd *pw;
if (getsockname(0, ...) < 0)
{
char *hostname;
char *virtual
...
/* Get our hostname base on the IP, and build a virtual user. */
asprintf (&virtual, "%s!%s", u, hostname);
return pop3d_virtual (virtual);
}
return NULL;
}
But I may missing some stuff.
--
alain