Fwd: [rt-users] canonicalising auto created user ids
Harald Wagener
hwagener at hamburg.fcb.com
Tue Nov 19 11:02:45 EST 2002
Hello list
Just for the record, here is another solution.
Regards,
Harald
>
> Hi Ray,
>
>>> Where is the auto creation handled? I might be able to hack a
>>> solution from there.
>>>
>
> Have a look at lib/RT/Interface/Email.pm:
>
> # Username is the 'Name' attribute of the user that RT uses for
> things
> # like authentication
> my $Username = undef;
>
> if ($RT::LookupSenderInExternalDatabase) {
> ($UserFoundInExternalDatabase, %UserInfo) =
> RT::LookupExternalUserInfo($Address, $Name);
> $Address = $UserInfo{'EmailAddress'};
> $Username = $UserInfo{'Name'};
> }
>
> This means that you'll have to look at LookupExternalUserInfo(), which
> is in etc/config.pm:
>
> I just added the line marked with *:
>
> #Name is the RT username you want to use for this user.
> $Name = $EmailAddress;
> * $Name =~ s/\@.*$//;
> $params{'Name'} = $Name;
>
> As Steph correctly stated, this is 'baaad'. But in our environment
> where only users from specific domains are allowed to send email to
> the queue (and their user part is unique), it's acceptable.
>
> Regards,
> Torsten
>
>
--
Harald Wagener * FCB/Wilkens * An der Alster 42 * 20099 Hamburg
More information about the rt-users
mailing list