Re: "From: address" has username prefix ...

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Jul 9, 2008 at 11:12 PM, Filip Novák <philip.x@xxxxxxxxx> wrote:
> Paul Lesniewski napsal(a):
>>>>>>>>>>> I have problem with "From:" address.
>>>>>>>>>>> /SquirrelMail 1.4.8-4.0.1.el5.centos.2, Sendmail 8.13.8-2/
>>>>>>>>>>>
>>>>>>>>>>> Linux mail users have prefix "m_", but email addresses are without prefix.
>>>>>>>>>>>
>>>>>>>>>>> /etc/mail/virtusertable:
>>>>>>>>>>> m_user      user@xxxxxxxxxxxxx
>>>>>>>>>>> ...................
>>>>>>>>>>>
>>>>>>>>>>> When I send message over client (Outlook Express) is "From:" address ok,
>>>>>>>>>>> but problem comes with SquirrelMail. There is address with prefix
>>>>>>>>>>> m_user@xxxxxxxxxxxxxx
>>>>>>>>>>> How can I change it?
>>>>>>>>>> Implement an outgoing conversion table in the MTA or change the email
>>>>>>>>>> address in Options->Personal Information (there are plugins that can
>>>>>>>>>> help automate that) or install the Login Manager (vlogin) plugin,
>>>>>>>>>> which can also remap the email address.  OTOH, maybe you should
>>>>>>>>>> implement a REAL virtual user system, instead of a hacked one.  If
>>>>>>>>>> mail users shouldn't have a real system account (they never should),
>>>>>>>>>> then don't give them one!
>>>>>>>>> I use vlogin plugin and users can login without prefix. But I don't know
>>>>>>>>> how to set outgoing address with vlogin...
>>>>>>>> Please turn on $rawLoginIsOutgoingEmailAddress in the config file.
>>>>>>>> >From what I understand, the login won't have a domain appendage, but
>>>>>>>> your MTA should add it, especially if you are only hosting one domain
>>>>>>>> on the machine.  Please give it a try and report back.
>>>>>>>>
>>>>>>> I'm very sorry, I made mistake (there is only ourdomain.com). I have
>>>>>>> problem with "m_" prefix in username. When user want to send message is
>>>>>>> "FROM address" m_user@xxxxxxxxxxxxx, not user@xxxxxxxxxxxxx which is right.
>>>>>>>
>>>>>>> (Turning on $rawLoginIsOutgoingEmailAddress really take away domain from
>>>>>>> address.)
>>>>>> I am unclear on the status of your issue.  Please tell me where the
>>>>>> problem lies:
>>>>>>
>>>>>> Real IMAP login:     m_user
>>>>>> "Nice" vlogin login:   user
>>>>>>
>>>>>> With $rawLoginIsOutgoingEmailAddress turned on, it should set the
>>>>>> outgoing email address to "user", which the MTA (actually,
>>>>>> SquirrelMail might do that first) should correct to
>>>>>> "user@xxxxxxxxxxx".  Is the problem that the MTA isn't doing that?
>>>>>> Did you test this?  Can you show a mail header?
>>>>>>
>>>>> I see, you're right. Now, with $rawLoginIsOutgoingEmailAddress turned on
>>>>> is email address only "user".
>>>>> Problem is sending message. Error: 64 Can't execute command
>>>>> '/usr/sbin/sendmail -i -t fuser@'.
>>>> Do you have the domain set in the SquirrelMail config??
>>> Yes.
>>>
>>> squirrelmail config.php
>>> -------------------------
>>> $domain                 = 'ourdomain.com';
>>> ...
>>>
>>> vlogin config.php
>>> -------------------------
>>> $virtualDomains = array(
>>>
>>>       'ourdomain.com' => array(
>>>          'domain'     => 'ourdomain.com',
>>>          'org_name'   => 'Company',
>>>        ),
>>> );
>>>
>>> $useDomainFromVirtDomainsArray = 1;
>>> $rawLoginIsOutgoingEmailAddress = 1;
>>> ...
>>
>> Looks to be a SM "bug".  Try this patch (also found here:
>> http://squirrelmail.svn.sourceforge.net/viewvc/squirrelmail/branches/SM-1_4-STABLE/squirrelmail/src/compose.php?r1=13223&r2=13222&view=patch&pathrev=13223):
>>
>> --- src/compose.php     (revision 13136)
>> +++ src/compose.php     (working copy)
>> @@ -1484,9 +1484,9 @@
>>          $from_mail = "$popuser@$domain";
>>      }
>>      $rfc822_header->from = $rfc822_header->parseAddress($from_mail,true);
>> +    if (!$rfc822_header->from[0]->host) $rfc822_header->from[0]->host
>> = $domain;
>>      if ($full_name) {
>>          $from = $rfc822_header->from[0];
>> -        if (!$from->host) $from->host = $domain;
>>          $full_name_encoded = encodeHeader($full_name);
>>          if ($full_name_encoded != $full_name) {
>>              $from_addr = $full_name_encoded .'
>> <'.$from->mailbox.'@'.$from->host.'>';
>>
>
> Thank you Paul, it works!!!
>
> Now there is only problem with address in "Options > Personal
> Information > Name and Address Options > E-mail address".  There is only
> "username". Is any patch for it?

That's not a "problem".  That's exactly what you told SM to put there
(using Vlogin).  You can put anything you want there, or you can turn
it off so users cannot edit it at all.  If you want to populate it
when first logging in using some different lookup or method, check out
the plugins recommended in the Vlogin configuration: Retrieve User
Data, Ask User Info, or New User Wizard.

-------------------------------------------------------------------------
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08
-----
squirrelmail-users mailing list
Posting guidelines: http://squirrelmail.org/postingguidelines
List address: squirrelmail-users@xxxxxxxxxxxxxxxxxxxxx
List archives: http://news.gmane.org/gmane.mail.squirrelmail.user
List info (subscribe/unsubscribe/change options): https://lists.sourceforge.net/lists/listinfo/squirrelmail-users


[Index of Archives]     [Video For Linux]     [Yosemite News]     [Yosemite Photos]     [gtk]     [KDE]     [Cyrus SASL]     [Gimp on Windows]     [Steve's Art]     [Webcams]

  Powered by Linux