1834089 Members
2254 Online
110063 Solutions
New Discussion

Length of User ID

 
Marty Metras
Super Advisor

Length of User ID

On our system HP-UX 11.0 when using SAM you can only have UserID 8 Charaters long. Is this a system limit that could be changed? Or is this just a SAM thing?

I want to create a userID "customer_service" to match the one used on our MS exchange server. This user would just send automatic confirming mail from the Unix box. The replies to the emails would go to the MS exchange box.

Marty
The only thing that always remain the same are the changes.
9 REPLIES 9
John Poff
Honored Contributor

Re: Length of User ID

Hi,

You are limited to 8 characters for the user ID. There is a patch that will let you go beyond 8 characters but it will probably break some other utilities and isn't worth the hassle.

My suggestion is to setup a user ID such as 'custsvc' on the Unix box and then use the alias function in sendmail to have the e-mail go out as customer_service. You can probably spoof the return address in the e-mail so that it points back to your M$ exchange box.

JP
K.Vijayaragavan.
Respected Contributor

Re: Length of User ID

Refer to the URL >>>
http://forums.itrc.hp.com/cm/QuestionAnswer/1,,0xafc650dde50cd71190050090279cd0f9,00.html
"Let us fine tune our knowledge together"
Patrick Wallek
Honored Contributor

Re: Length of User ID

Have a look at TKB document KBRC00008099 here:
http://www1.itrc.hp.com/service/cki/docDisplay.do?docLocale=en_US&docId=200000065679828

It mentions that this can be enabled with patch PHCO_21833. The most current version of that is PHCO_26089. You can read about it here:

http://www1.itrc.hp.com/service/patch/patchDetail.do?patchid=PHCO_26089&context=hpux:800:11:00

Sridhar Bhaskarla
Honored Contributor

Re: Length of User ID

Hi Marty,

HP does have the limitation of usernames to 8 chars. You can install the patch PHCO_26089 to bypass the limitation but note the following from the patch's description.

//
Resolution:
libpam_unix.1 now checks for the existence of a file
in the "/etc/default" directory called:
"I_ACCEPT_RESPONSIBILITY_FOR_BYPASSING_SECURITY_CHECKS".
If this file exists, then login names longer than 8
characters can be added to /etc/passwd, and then those
users can login. Note the following restrictions:
1) HP has never claimed that HP-UX supports user names
longer than 8 characters, and does not recommend that
customers bypass the existing length checks. Doing
so may cause functional and/or security problems.
2) This patch does not remove the existing user name
length checks from other commands - e.g. pwck(1m),
sam(1m), useradd(1m).
3) Do not enable long usernames on trusted system
configurations.

//

So, with that you cannot get the SAM functionality, but you can manually create the entries.

-Sri
You may be disappointed if you fail, but you are doomed if you don't try
Pete Randall
Outstanding Contributor

Re: Length of User ID

Marty,

Though the userid can be extended beyond 8 characters (via a patch, I think) you really don't want to do that. You'll end up creating many other problems for your self. Abbreviate instead.

Pete

Pete
A. Clay Stephenson
Acclaimed Contributor

Re: Length of User ID

This is not a SAM thing; it is a UNIX thing. There are patches to increase this limit but don't do it. Applications will almost certainly break.
If it ain't broke, I can fix that.
Marty Metras
Super Advisor

Re: Length of User ID

John,

Sounds like it isn't a good idea to change the lengh of the userID.
My HP box is only setup to send email.
By putting in an /etc/aliases is it not for receiving email?
How would I get that to be used as the Return/Replay address?

I will be reading a database to get an email address and sending a generic confirm and did not want any email to be sent back to the HP.
How would I send an email where the Return/Reply address is different than the user?
I have am running sendmail and using a simple script to do it. like this
mailx -s '"$SUBJECT"' $ADDRESS < $MESSAGE_FILE

Marty
The only thing that always remain the same are the changes.
John Poff
Honored Contributor

Re: Length of User ID

Marty,

Here is a way that I think you can do it. First, you'll need the alias for the 'custsvc' [or whatever ID you give it] to map to customer_service, so you'll need an entry in /etc/mail/aliases like this:

custsvc : customer_service@mydomain.com


Be sure to do a 'newaliases' command after updating the aliases file to get it into the database.

Then, you'll need to use the 'DM' macro keyword in your sendmail config file to masquerade your domain, so you'll have an entry there like this:

DMmydomain.com


We use the 'DM' macro in the sendmail config on all our HP-UX boxes and email from 'root' on all the boxes comes to us as 'root@ourdomain.com', and if I try to reply to the e-mail it goes back to that same e-mail address.

I'm not a sendmail guru and others should chime in here if I've got it wrong.

JP
Bill Hassell
Honored Contributor

Re: Length of User ID

email aliases can be quite lengthy and don't even have to refer to an actual user on the system--the alias customer_service can be sent to a processing script which can parse the headers and text and perform other tasks.

If the email is addressed to customer_service@machine.com, the alias might read:

customer_service: custserv

where custserv is a real user. Now if a 'real' user replies, you can use the -r option for mailx or even -f option of sendmail (with restrictions). Your script would look like this:

mailx -s '"$SUBJECT"' -r customer_service@mymachine.com $ADDRESS < $MESSAGE_FILE

NOTE: The header will contain a note that the reply address is different than the sender's which part of being a good citizen in a world of spam...but may occasionally get bounced due to over-zealous spam filters.


Bill Hassell, sysadmin