public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
* Can you modify how Cygwin prepends domain name to username?
@ 2016-09-08 12:14 Carl
  2016-09-08 12:26 ` Marco Atzeri
  0 siblings, 1 reply; 7+ messages in thread
From: Carl @ 2016-09-08 12:14 UTC (permalink / raw)
  To: cygwin

Hi folks,

Is is posible to modify the behavior of how Cygwin prepends a domain
name to a username?

I need to setup GPFS in an environment where the PC is a member of one
domain and the user that the sshd service will run as is a member of a
different domain.
There is a trust relationship between the domains, however the user
has its domain name prepended and this breaks things for setting up
GPFS.

ie:
ADUNSW+root@gpfs2-pc:~ $ mkpasswd.exe -c
ADUNSW+root:*:2149521262:2147484161:U-ADUNSW\root,S-1-5-21-1140405718-358989843-3445714273-2037614:/home/root:/bin/bash

I welcome any suggestions on how I might be able to work around this?

Thanks,

Carl.

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Can you modify how Cygwin prepends domain name to username?
  2016-09-08 12:14 Can you modify how Cygwin prepends domain name to username? Carl
@ 2016-09-08 12:26 ` Marco Atzeri
  2016-09-08 13:17   ` Carl
  0 siblings, 1 reply; 7+ messages in thread
From: Marco Atzeri @ 2016-09-08 12:26 UTC (permalink / raw)
  To: cygwin

On 08/09/2016 14:14, Carl wrote:
> Hi folks,
>
> Is is posible to modify the behavior of how Cygwin prepends a domain
> name to a username?
>
> I need to setup GPFS in an environment where the PC is a member of one
> domain and the user that the sshd service will run as is a member of a
> different domain.
> There is a trust relationship between the domains, however the user
> has its domain name prepended and this breaks things for setting up
> GPFS.
>
> ie:
> ADUNSW+root@gpfs2-pc:~ $ mkpasswd.exe -c
> ADUNSW+root:*:2149521262:2147484161:U-ADUNSW\root,S-1-5-21-1140405718-358989843-3445714273-2037614:/home/root:/bin/bash
>
> I welcome any suggestions on how I might be able to work around this?
>
> Thanks,
>
> Carl.
>


mkpasswd.exe -c > /etc/passwd

and change in /etc/passwd the user name "ADUNSW+root" to what you want.

Regards
Marco

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Can you modify how Cygwin prepends domain name to username?
  2016-09-08 12:26 ` Marco Atzeri
@ 2016-09-08 13:17   ` Carl
  2016-09-08 19:44     ` Linda Walsh
  0 siblings, 1 reply; 7+ messages in thread
From: Carl @ 2016-09-08 13:17 UTC (permalink / raw)
  To: cygwin

Thanks for the quick response Marco.

I have been doing that as a work around. However I have been getting
some inconsistent behavior, for example a couple of times bash has
reverted to the id of ADUNSW+root and has had to be restarted.

Are there any other knobs to tweak?

Cheers,

Carl.

On 8 September 2016 at 22:26, Marco Atzeri <marco.atzeri@gmail.com> wrote:
> On 08/09/2016 14:14, Carl wrote:
>>
>> Hi folks,
>>
>> Is is posible to modify the behavior of how Cygwin prepends a domain
>> name to a username?
>>
>> I need to setup GPFS in an environment where the PC is a member of one
>> domain and the user that the sshd service will run as is a member of a
>> different domain.
>> There is a trust relationship between the domains, however the user
>> has its domain name prepended and this breaks things for setting up
>> GPFS.
>>
>> ie:
>> ADUNSW+root@gpfs2-pc:~ $ mkpasswd.exe -c
>>
>> ADUNSW+root:*:2149521262:2147484161:U-ADUNSW\root,S-1-5-21-1140405718-358989843-3445714273-2037614:/home/root:/bin/bash
>>
>> I welcome any suggestions on how I might be able to work around this?
>>
>> Thanks,
>>
>> Carl.
>>
>
>
> mkpasswd.exe -c > /etc/passwd
>
> and change in /etc/passwd the user name "ADUNSW+root" to what you want.
>
> Regards
> Marco
>
> --
> Problem reports:       http://cygwin.com/problems.html
> FAQ:                   http://cygwin.com/faq/
> Documentation:         http://cygwin.com/docs.html
> Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
>

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Can you modify how Cygwin prepends domain name to username?
  2016-09-08 13:17   ` Carl
@ 2016-09-08 19:44     ` Linda Walsh
  2016-09-08 23:39       ` Carl
  0 siblings, 1 reply; 7+ messages in thread
From: Linda Walsh @ 2016-09-08 19:44 UTC (permalink / raw)
  To: cygwin

Carl wrote:
ADUNSW+root:*:2149521262:2147484161:U-ADUNSW\root, 
      S-1-5-21-1140405718-358989843-3445714273-2037614:/home/root:/bin/bash
---
Where does the '+' come from?  Is that in Win10 or some newer domain
control software?

I'm running Windows 7, and cygwin uses the same naming conventions
as the OS.  I.e. in Windows, outside of cygwin, my domain logins 
look like "Domain\user".  So in my /etc/passwd file, I see the same thing:
Domain\user.  

I would be nervous to change the form in /etc/passwd to something
different from the OS's name for the account, but it might make
no difference.    

How does your local Win OS name such accounts?  I.e. if I use
Process Hacker, it can show the user account for each 
process, as obtained from Windows.  It always shows 
Domain/user for the non-local users running programs. 




--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Can you modify how Cygwin prepends domain name to username?
  2016-09-08 19:44     ` Linda Walsh
@ 2016-09-08 23:39       ` Carl
  2016-09-09  4:28         ` Linda Walsh
  2016-09-09 10:47         ` Corinna Vinschen
  0 siblings, 2 replies; 7+ messages in thread
From: Carl @ 2016-09-08 23:39 UTC (permalink / raw)
  To: cygwin

Hi Linda,

The plus character is the default separator for mkpasswd.

In the help for it (mkpasswd -h), you will see

   -S,--separator char     For -L use character char as domain\user
                           separator in username instead of the default '+'.

Cheers,

Carl.



On 9 September 2016 at 05:44, Linda Walsh <cygwin@tlinx.org> wrote:
> Carl wrote:
> ADUNSW+root:*:2149521262:2147484161:U-ADUNSW\root,
> S-1-5-21-1140405718-358989843-3445714273-2037614:/home/root:/bin/bash
> ---
> Where does the '+' come from?  Is that in Win10 or some newer domain
> control software?
>
> I'm running Windows 7, and cygwin uses the same naming conventions
> as the OS.  I.e. in Windows, outside of cygwin, my domain logins look like
> "Domain\user".  So in my /etc/passwd file, I see the same thing:
> Domain\user.
> I would be nervous to change the form in /etc/passwd to something
> different from the OS's name for the account, but it might make
> no difference.
> How does your local Win OS name such accounts?  I.e. if I use
> Process Hacker, it can show the user account for each process, as obtained
> from Windows.  It always shows Domain/user for the non-local users running
> programs.
>
>
>
> --
> Problem reports:       http://cygwin.com/problems.html
> FAQ:                   http://cygwin.com/faq/
> Documentation:         http://cygwin.com/docs.html
> Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
>

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Can you modify how Cygwin prepends domain name to username?
  2016-09-08 23:39       ` Carl
@ 2016-09-09  4:28         ` Linda Walsh
  2016-09-09 10:47         ` Corinna Vinschen
  1 sibling, 0 replies; 7+ messages in thread
From: Linda Walsh @ 2016-09-09  4:28 UTC (permalink / raw)
  To: cyg >> "cygwin@cygwin.com"

Carl wrote:
> Hi Linda,
> 
> The plus character is the default separator for mkpasswd.
> 
> In the help for it (mkpasswd -h), you will see
> 
>    -S,--separator char     For -L use character char as domain\user
>                            separator in username instead of the default '+'.
---
??? Really?
But how is that compatible with Win's USERNAME?  ...
I even use Domain\User on my linux domain server!  So that would
conflict, by default.  When I login to linux from win, it logs in
as Domain\User.  Not entirely right for a PDC but at least somewhat
consistent.  Domain+User would be entirely broken.

Yes -- I have added '\' to my allowed userID set on linux
in /etc/login.defs.


--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Can you modify how Cygwin prepends domain name to username?
  2016-09-08 23:39       ` Carl
  2016-09-09  4:28         ` Linda Walsh
@ 2016-09-09 10:47         ` Corinna Vinschen
  1 sibling, 0 replies; 7+ messages in thread
From: Corinna Vinschen @ 2016-09-09 10:47 UTC (permalink / raw)
  To: cygwin

[-- Attachment #1: Type: text/plain, Size: 1073 bytes --]

Hi Carl,

Please don't https://cygwin.com/acronyms/#TOFU

Thank you.

On Sep  9 09:39, Carl wrote:
> Hi Linda,
> 
> On 9 September 2016 at 05:44, Linda Walsh <cygwin@tlinx.org> wrote:
> > Carl wrote:
> > ADUNSW+root:*:2149521262:2147484161:U-ADUNSW\root,
> > S-1-5-21-1140405718-358989843-3445714273-2037614:/home/root:/bin/bash
> > ---
> > Where does the '+' come from?  Is that in Win10 or some newer domain
> > control software?
> 
> The plus character is the default separator for mkpasswd.
> 
> In the help for it (mkpasswd -h), you will see
> 
>    -S,--separator char     For -L use character char as domain\user
>                            separator in username instead of the default '+'.

No, no.  Mkpasswd uses the '+' only by default because Cygwin uses it.

The full answer to the question is in the docs:

  https://cygwin.com/cygwin-ug-net/ntsec.html#ntsec-mapping


Corinna

-- 
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Maintainer                 cygwin AT cygwin DOT com
Red Hat

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 819 bytes --]

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2016-09-09 10:47 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-09-08 12:14 Can you modify how Cygwin prepends domain name to username? Carl
2016-09-08 12:26 ` Marco Atzeri
2016-09-08 13:17   ` Carl
2016-09-08 19:44     ` Linda Walsh
2016-09-08 23:39       ` Carl
2016-09-09  4:28         ` Linda Walsh
2016-09-09 10:47         ` Corinna Vinschen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).