RE: username should be lower-case for $USER
On 10-jan-2007 Dave Korn wrote: On 09 January 2007 22:15, David Smiley wrote: I forgot to add, I log into a windows domain and so I can't set the case. Perhaps this issue only relates to windows domain logins. Maybe they are case insensitive because when I log into the domain, I ALWAYS specify it in lower case. I don't think I've ever seen it presented to me (in Windows) as upper case. Yet in CYGWIN, $USER=DSMILEY. If domain logins are case *in*sensitive (appears likely), then it would seem to me that it should be normalized to lower-case for use in CYGWIN. That's a non-sequitur. It should not be /normalised/; it should be *canonicalised*. And the canonical definition is whatever your domain server reports to cygwin that your user name is. Case-preserving but case-insensitive, remember? Since it's insensitive, just hand-edit your /etc/passwd to look the way you like and you're done. BTW, I log-on to a domain, and my $USER name has always been lower-case. It's just the way your admin has created your account. I also log into a domain, and my username there is 'LongPhil'. I have gone through several computers while at this job, and have transferred stuff from one machine to the next each time. Our MIS department allowed _me_ to log in when setting up initially most times, after which they took over and did their thing (although it's almost all automated now; we're at the cutting edge of the late 1980s). Sometimes I logged in as 'LongPhil', and sometimes as 'longphil'; depending on how _I_ logged in, the local profile was created with _that_ _name_ _and_ _case_. Forever afterwards, most, if not all, references to my account made by the system used the same case that I used. If your MIS guys don't allow U to log in to a new machine the first time, maybe they're using all uppercase characters when they log in using your account. The profile would then be 'DSMILEY', not 'dsmiley'. FREE Reminder Service - NEW from AmericanGreetings.com Click HERE and never forget a Birthday or Anniversary again! http://track.juno.com/s/lc?s=197335u=http://www.americangreetings.com/products/online_calendar.pd?c=uol5752 -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
RE: username should be lower-case for $USER
On 09 January 2007 22:15, David Smiley wrote: I forgot to add, I log into a windows domain and so I can't set the case. Perhaps this issue only relates to windows domain logins. Maybe they are case insensitive because when I log into the domain, I ALWAYS specify it in lower case. I don't think I've ever seen it presented to me (in Windows) as upper case. Yet in CYGWIN, $USER=DSMILEY. If domain logins are case *in*sensitive (appears likely), then it would seem to me that it should be normalized to lower-case for use in CYGWIN. That's a non-sequitur. It should not be /normalised/; it should be *canonicalised*. And the canonical definition is whatever your domain server reports to cygwin that your user name is. Case-preserving but case-insensitive, remember? Since it's insensitive, just hand-edit your /etc/passwd to look the way you like and you're done. BTW, I log-on to a domain, and my $USER name has always been lower-case. It's just the way your admin has created your account. cheers, DaveK -- Can't think of a witty .sigline today -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
RE: Re: username should be lower-case for $USER
...snip... If the user ID is created with lower-cased letters, it will be stored and reported in lower-cased letters. At least that is how the Windows 2003 Active Directory where I work expresses its user IDs. ...snip... U-huh. Just played around in the GUI and that seems to be true. I reckon I was getting confused with some APIs returning in upper. The comparisons Certainly are case insensitive, tho. TFT! -doug -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
username should be lower-case for $USER
I am new to Cygwin. I noticed that the $USER environment variable has my username in upper-case. So it is DSMILEY. On unix based hosts I log into, it is always lower-case. So if I try to SSH to another machine where I have the same login name, I can't let SSH automatically default to $USER because the case isn't right. *Even if* Windows user names are case sensitive and so there is a difference between DSMILEY and dsmiley (are they?, I don't know) I think $USER should be made to be all lower-case to be consistent with unix environments. ~ David Smiley -- View this message in context: http://www.nabble.com/username-should-be-lower-case-for-%24USER-tf2947156.html#a8241120 Sent from the Cygwin Users mailing list archive at Nabble.com. -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
Re: username should be lower-case for $USER
David Smiley escribe: I am new to Cygwin. I noticed that the $USER environment variable has my username in upper-case. So it is DSMILEY. On unix based hosts I log into, it is always lower-case. So if I try to SSH to another machine where I have the same login name, I can't let SSH automatically default to $USER because the case isn't right. *Even if* Windows user names are case sensitive and so there is a difference between DSMILEY and dsmiley (are they?, I don't know) I think $USER should be made to be all lower-case to be consistent with unix environments. Making ssh use different user names for logging in to different hosts is obvious enough IMO. Cordially, Ismael -- Ismael Valladolid Torres m. +34679156321 [1]La media hostiaj. [EMAIL PROTECTED] 1. http://lamediahostia.blogspot.com/ -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
RE: username should be lower-case for $USER
On 09 January 2007 16:25, David Smiley wrote: I am new to Cygwin. I noticed that the $USER environment variable has my username in upper-case. So it is DSMILEY. On unix based hosts I log into, it is always lower-case. So if I try to SSH to another machine where I have the same login name, I can't let SSH automatically default to $USER because the case isn't right. *Even if* Windows user names are case sensitive and so there is a difference between DSMILEY and dsmiley (are they?, I don't know) I think $USER should be made to be all lower-case to be consistent with unix environments. It would /not/ be consistent with unix environments. Just because *you* haven't used one with capitals in usernames does *not* mean they do not exist. The Opengroup posix spec quite explicitly allows different cases: http://www.opengroup.org/onlinepubs/009695399/basedefs/xbd_chap03.html#tag_03_ 426 cheers, DaveK -- Can't think of a witty .sigline today -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
Re: username should be lower-case for $USER
I know this is clearly a minor problem I am reporting, but a problem nonetheless. Ismael Valladolid Torres-4 wrote: David Smiley escribe: I am new to Cygwin. I noticed that the $USER environment variable has my username in upper-case. So it is DSMILEY. On unix based hosts I log into, it is always lower-case. So if I try to SSH to another machine where I have the same login name, I can't let SSH automatically default to $USER because the case isn't right. *Even if* Windows user names are case sensitive and so there is a difference between DSMILEY and dsmiley (are they?, I don't know) I think $USER should be made to be all lower-case to be consistent with unix environments. Making ssh use different user names for logging in to different hosts is obvious enough IMO. Cordially, Ismael -- Ismael Valladolid Torres m. +34679156321 [1]La media hostiaj. [EMAIL PROTECTED] 1. http://lamediahostia.blogspot.com/ -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/ -- View this message in context: http://www.nabble.com/username-should-be-lower-case-for-%24USER-tf2947156.html#a8241408 Sent from the Cygwin Users mailing list archive at Nabble.com. -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
RE: username should be lower-case for $USER
Change the username to lower case on Your Windows login or at least within cygwins /etc/passwd ... -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of David Smiley Sent: Tuesday, January 09, 2007 5:25 PM To: cygwin@cygwin.com Subject: username should be lower-case for $USER I am new to Cygwin. I noticed that the $USER environment variable has my username in upper-case. So it is DSMILEY. On unix based hosts I log into, it is always lower-case. So if I try to SSH to another machine where I have the same login name, I can't let SSH automatically default to $USER because the case isn't right. *Even if* Windows user names are case sensitive and so there is a difference between DSMILEY and dsmiley (are they?, I don't know) I think $USER should be made to be all lower-case to be consistent with unix environments. ~ David Smiley -- View this message in context: http://www.nabble.com/username-should-be-lower-case-for-%24USER-tf294715 6.html#a8241120 Sent from the Cygwin Users mailing list archive at Nabble.com. -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/ -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
Re: username should be lower-case for $USER
TDavid Smiley wrote: I am new to Cygwin. I noticed that the $USER environment variable has my username in upper-case. So it is DSMILEY. As David said, that's because you created your username in ALL UPPERCASE when setting up the user on Windows. The only way to fix this for you would be to rename your Windows user to have a lower-case name. (If windows allows that operation..) -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
RE: username should be lower-case for $USER
I forgot to add, I log into a windows domain and so I can't set the case. Perhaps this issue only relates to windows domain logins. Maybe they are case insensitive because when I log into the domain, I ALWAYS specify it in lower case. I don't think I've ever seen it presented to me (in Windows) as upper case. Yet in CYGWIN, $USER=DSMILEY. If domain logins are case *in*sensitive (appears likely), then it would seem to me that it should be normalized to lower-case for use in CYGWIN. Dave Korn wrote: On 09 January 2007 16:25, David Smiley wrote: I am new to Cygwin. I noticed that the $USER environment variable has my username in upper-case. So it is DSMILEY. On unix based hosts I log into, it is always lower-case. So if I try to SSH to another machine where I have the same login name, I can't let SSH automatically default to $USER because the case isn't right. *Even if* Windows user names are case sensitive and so there is a difference between DSMILEY and dsmiley (are they?, I don't know) I think $USER should be made to be all lower-case to be consistent with unix environments. It would /not/ be consistent with unix environments. Just because *you* haven't used one with capitals in usernames does *not* mean they do not exist. The Opengroup posix spec quite explicitly allows different cases: http://www.opengroup.org/onlinepubs/009695399/basedefs/xbd_chap03.html#tag_03_ 426 cheers, DaveK -- Can't think of a witty .sigline today -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/ -- View this message in context: http://www.nabble.com/username-should-be-lower-case-for-%24USER-tf2947156.html#a8247784 Sent from the Cygwin Users mailing list archive at Nabble.com. -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
Re: username should be lower-case for $USER
On 1/9/07, Shankar Unni wrote: TDavid Smiley wrote: I am new to Cygwin. I noticed that the $USER environment variable has my username in upper-case. So it is DSMILEY. As David said, that's because you created your username in ALL UPPERCASE when setting up the user on Windows. The only way to fix this for you would be to rename your Windows user to have a lower-case name. (If windows allows that operation..) My user ID is numbers only so I cannot test this. The suggestion of just renaming your user account is actually the easiest one if you have administrative rights in your domain. But I do have a few other suggestions in case you don't. Since Windows is not a case-sensitive operating system and since the $USER environment variable is dynamically populated when you logon, try logging on with your user name as 'dsmiley' instead of 'DSMILEY' and see if that changes the environment variable. If it doesn't, you may be able to fix it by deleting your user profile and then logging on with your user name in lower case. As I said, Windows is not case-sensitive as far as user names go. You can log on as 'DSMILEY', 'dsmiley', or 'DsMiLEy' and it will work. But I don't know if it will change your $USER environment variable because I don't know exactly how Windows populates it. -Jason -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
Re: username should be lower-case for $USER
On 1/9/07, David Smiley wrote: I forgot to add, I log into a windows domain and so I can't set the case. Perhaps this issue only relates to windows domain logins. Maybe they are case insensitive because when I log into the domain, I ALWAYS specify it in lower case. I don't think I've ever seen it presented to me (in Windows) as upper case. Yet in CYGWIN, $USER=DSMILEY. If domain logins are case *in*sensitive (appears likely), then it would seem to me that it should be normalized to lower-case for use in CYGWIN. $USER is a Windows environment variable and Cygwin doesn't change it. It just reports what Windows says. I disagree that Cygwin should normalize it to lower case by default. You can do something creative with your logon process by sending the variable to some shell script and having it fix the case. I don't write bash scripts or awk so here is an example in perl. =-=-=-=-=-=-=-=-=-=-=-=-= code =-=-=-=-=-=-=-=-=-=-=-=-= #!/usr/bin/perl -w $word = shift; print In: $word\n; $word =~ s/([A-Z])/lc($1)/ge; print Out: $word\n; =-=-=-=-=-=-=-=-=-=-=-=-= code =-=-=-=-=-=-=-=-=-=-=-=-= Examples of output: [EMAIL PROTECTED] ~ $ ./test3.pl DSmiley In: DSmiley Out: dsmiley [EMAIL PROTECTED] ~ $ ./test3.pl DSMILEY In: DSMILEY Out: dsmiley [EMAIL PROTECTED] ~ $ ./test3.pl dsmiley In: dsmiley Out: dsmiley [EMAIL PROTECTED] ~ $ -Jason -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
Re: username should be lower-case for $USER
On Tue, 9 Jan 2007, DePriest, Jason R. wrote: On 1/9/07, David Smiley wrote: I forgot to add, I log into a windows domain and so I can't set the case. Perhaps this issue only relates to windows domain logins. Maybe they are case insensitive because when I log into the domain, I ALWAYS specify it in lower case. I don't think I've ever seen it presented to me (in Windows) as upper case. Yet in CYGWIN, $USER=DSMILEY. If domain logins are case *in*sensitive (appears likely), then it would seem to me that it should be normalized to lower-case for use in CYGWIN. $USER is a Windows environment variable and Cygwin doesn't change it. It just reports what Windows says. Not true. $USER is actually a shell variable, and is (re)set by the shell (bash, ash, tcsh, what have you). You must be thinking of $USERNAME, which is a Windows variable. Cygwin sets it from the data it finds in /etc/passwd. In fact, the only thing that Cygwin actually uses is the SID in /etc/passwd -- everything else (including the username) is under the user's control. I disagree that Cygwin should normalize it to lower case by default. You can do something creative with your logon process by sending the variable to some shell script and having it fix the case. [snip perl script] Or you can edit /etc/passwd and make your username whatever you wish it to be (just be sure to leave the SID unchanged). For more information, see the NTSEC section of the User's Guide (outdated as it is). Igor -- http://cs.nyu.edu/~pechtcha/ |\ _,,,---,,_[EMAIL PROTECTED] | [EMAIL PROTECTED] ZZZzz /,`.-'`'-. ;-;;,_Igor Peshansky, Ph.D. (name changed!) |,4- ) )-,_. ,\ ( `'-' old name: Igor Pechtchanski '---''(_/--' `-'\_) fL a.k.a JaguaR-R-R-r-r-r-.-.-. Meow! Freedom is just another word for nothing left to lose... -- Janis Joplin -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
RE: Re: username should be lower-case for $USER
Hi all, My first constructive post to this group outside of my inane question asking... TDavid Smiley wrote: I am new to Cygwin. I noticed that the $USER environment variable has my username in upper-case. So it is DSMILEY. As David said, that's because you created your username in ALL UPPERCASE when setting up the user on Windows. The only way to fix this for you would be to rename your Windows user to have a lower-case name. (If windows allows that operation..) As covered later in this thread the user is logging into a domain. Windows is indeed case insensitive WRT logins and can even be forced into case insensitive mode for passwords programatically (as demonstrated by the l0phtcrack algorithm). But I have never seen a DOMAIN report the user id back in lowercase, even when it was specifically entered in lower case (I may be wrong about this - please let me know if you have contrary evidence). There is another workaround, tho! In my environment I log into the domain with a login in the form AA, but need my Cygwin environment to recognise me as sybase. So I simply edited the leading column of my record in /etc/passwd and changed the contents sybase. Since the other tokens linking me record to the domain account were unchanged Cygwin sees me as sybase, but the domain sees me as myself. This has been working for well over a year. If anyone sees any problems with it I'd be glad to hear form them. -doug echo '[q]sa[ln0=aln256%Pln256/snlbx]sb3135071790101768542287578439snlbxq' |dc -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
Re: Re: username should be lower-case for $USER
First - On 1/9/07, Igor Peshansky wrote: On Tue, 9 Jan 2007, DePriest, Jason R. wrote: $USER is a Windows environment variable and Cygwin doesn't change it. It just reports what Windows says. Not true. $USER is actually a shell variable, and is (re)set by the shell (bash, ash, tcsh, what have you). You must be thinking of $USERNAME, which is a Windows variable. Yes, you are exactly correct. I goobered that and I am glad you caught it and put it out there so at least the archives will reflect the truth. Next - On 1/9/07, Irwin, Doug wrote: As covered later in this thread the user is logging into a domain. Windows is indeed case insensitive WRT logins and can even be forced into case insensitive mode for passwords programatically (as demonstrated by the l0phtcrack algorithm). But I have never seen a DOMAIN report the user id back in lowercase, even when it was specifically entered in lower case (I may be wrong about this - please let me know if you have contrary evidence). If the user ID is created with lower-cased letters, it will be stored and reported in lower-cased letters. At least that is how the Windows 2003 Active Directory where I work expresses its user IDs. For example, our regular IDs are a number. Some special IDs have letters added to the beginning of the number. I am looking at user IDs right now through the AD User and Computers mmc snap-in and I can see that most of them are in all caps, but some are not. No matter how I look at the account name for this particular ID, it is in lower-cased letters. The reported 'dn' of objects with lower-cased letters have lower-cased letters in them, so AD will use that to report the values. I also know that when you initially log on to a system and it creates a new user profile for you, the folder it creates will have upper / lower -cased letters based on how you logged on and not on how AD says your ID should be capitalized. There is another workaround, tho! In my environment I log into the domain with a login in the form AA, but need my Cygwin environment to recognise me as sybase. So I simply edited the leading column of my record in /etc/passwd and changed the contents sybase. Since the other tokens linking me record to the domain account were unchanged Cygwin sees me as sybase, but the domain sees me as myself. This has been working for well over a year. If anyone sees any problems with it I'd be glad to hear form them. -doug This is of course the new best answer to the problem and is something I also routinely do (mostly to distinguish between groups that are in different domains but would otherwise have the same name). I have no idea why it wasn't suggested earlier unless we all just thought he had probably already tried that. -Jason -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/