From: "Dmitry V. Levin" <ldv@altlinux.org> To: ALT Linux Community general discussions <community@lists.altlinux.org> Subject: Re: [Comm] passwd after su - Date: Tue, 17 Mar 2015 01:09:50 +0300 Message-ID: <20150316220950.GA7675@altlinux.org> (raw) In-Reply-To: <55074A7A.5020503@complife.ru> [-- Attachment #1: Type: text/plain, Size: 1085 bytes --] On Mon, Mar 16, 2015 at 10:26:18PM +0100, Michael A. Kangin wrote: > 16.03.2015 21:31, Dmitry V. Levin пишет: > > >>[root@mak-ws ~]# passwd > >>passwd: updating all authentication tokens for user mak. > > > >Традиционно passwd по умолчанию меняет > >пароль того же самого пользователя, > >которого показывает logname(1). В вашем > >случае: > > > >[root@mak-ws ~]# logname > >mak > > Ok, похоже на то. > Но, возвращаясь к, правильно ли такое > поведение? Это традиционное поведение. passwd традиционно использует getlogin(3) для получения имени пользователя по умолчанию. > DESCRIPTION > Print the name of the current user. В этом описании ошибка, приехавшая из второй строки вывода "logname --help". В "info logname" лучше написано. В SUSv3 про logname еще более четко сказано: "The logname utility shall write the user's login name to standard output. The login name shall be the string that would be returned by the getlogin() function". В современных системах getlogin(3) получает информацию из /proc/self/loginuid. -- ldv [-- Attachment #2: Type: application/pgp-signature, Size: 181 bytes --]
next prev parent reply other threads:[~2015-03-16 22:09 UTC|newest] Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top 2015-03-16 17:16 Michael A. Kangin 2015-03-16 17:28 ` Michael Shigorin 2015-03-16 17:34 ` Speccyfighter 2015-03-16 17:41 ` Ruslan Hihin 2015-03-16 20:24 ` Speccyfighter 2015-03-16 21:31 ` Michael A. Kangin 2015-03-16 22:20 ` Speccyfighter 2015-03-16 20:31 ` Dmitry V. Levin 2015-03-16 21:26 ` Michael A. Kangin 2015-03-16 22:09 ` Dmitry V. Levin [this message] 2015-03-17 1:46 ` Hihin Ruslan 2015-03-17 2:33 ` Dmitry V. Levin 2015-03-17 2:36 ` REAL 2015-03-17 2:51 ` Hihin Ruslan 2015-03-17 2:54 ` REAL 2015-03-17 4:13 ` Hihin Ruslan 2015-03-17 4:15 ` REAL 2015-03-17 4:29 ` Hihin Ruslan 2015-03-17 4:32 ` REAL 2015-03-17 11:24 ` Michael Shigorin 2015-03-17 11:46 ` Michael Shigorin
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20150316220950.GA7675@altlinux.org \ --to=ldv@altlinux.org \ --cc=community@lists.altlinux.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: link
ALT Linux Community general discussions This inbox may be cloned and mirrored by anyone: git clone --mirror http://lore.altlinux.org/community/0 community/git/0.git # If you have public-inbox 1.1+ installed, you may # initialize and index your mirror using the following commands: public-inbox-init -V2 community community/ http://lore.altlinux.org/community \ mandrake-russian@linuxteam.iplabs.ru community@lists.altlinux.org community@lists.altlinux.ru community@lists.altlinux.com public-inbox-index community Example config snippet for mirrors. Newsgroup available over NNTP: nntp://lore.altlinux.org/org.altlinux.lists.community AGPL code for this site: git clone https://public-inbox.org/public-inbox.git