(232921) somewhat random pw-related errors following system upgrades (was: freebsd-update(8) without an echo of "You must be root to run this.")

2021-02-20 Thread Graham Perrin
On 19/02/2021 21:59, Chris Rees wrote: Hey, On 16 February 2021 08:53:29 GMT, Graham Perrin wrote:         echo "You must be root to run this." Below: is this my

Re: svn commit: r336751 - head/usr.sbin/pw

2018-07-27 Thread Li-Wen Hsu
On Fri, Jul 27, 2018 at 4:22 PM Ian Lepore wrote: > This was just an error on my part, the code was wrong and I fixed it in > r336762. This time I made sure the kyua tests pass first. > > I had intended to run the kyua tests before and after re-applying my > changes to pw(8).

Re: svn commit: r336751 - head/usr.sbin/pw

2018-07-27 Thread Ian Lepore
> > Log: > >   Re-apply r336625 which was reverted with r336638, now that the underlying > >   pw_scan(3) has been fixed in a way that doesn't perturb other callers of > >   it or the getpwnam(3) family. > >    > >   Make pw(8) showuser work the same with or witho

Re: svn commit: r336751 - head/usr.sbin/pw

2018-07-27 Thread Li-Wen Hsu
t; pw_scan(3) has been fixed in a way that doesn't perturb other callers of > it or the getpwnam(3) family. > > Make pw(8) showuser work the same with or without -R for non-root > users. Without -R, pw(8) uses getpwnam(3), which will open master.passwd > for the root user

Re: mount_smbfs gives error when stored crypted pw is used

2017-06-07 Thread Josh Paetzel
On Wed, Jun 7, 2017, at 12:29 PM, O. Hartmann wrote: > Am Wed, 7 Jun 2017 19:22:34 +0200 > Matthias Apitz schrieb: > > > El día miércoles, junio 07, 2017 a las 02:35:31p. m. +0200, Matthias Apitz > > escribió: > > > > > I have located the bug in

Re: mount_smbfs gives error when stored crypted pw is used

2017-06-07 Thread O. Hartmann
Am Wed, 7 Jun 2017 19:22:34 +0200 Matthias Apitz schrieb: > El día miércoles, junio 07, 2017 a las 02:35:31p. m. +0200, Matthias Apitz > escribió: > > > I have located the bug in /usr/src/contrib/smbfs/lib/smb/subr.c > > > > The printf(3C) calls have been added for

Re: mount_smbfs gives error when stored crypted pw is used

2017-06-07 Thread Matthias Apitz
El día miércoles, junio 07, 2017 a las 02:35:31p. m. +0200, Matthias Apitz escribió: > I have located the bug in /usr/src/contrib/smbfs/lib/smb/subr.c > > The printf(3C) calls have been added for debugging; the bug is the > addition of 13 after crypting every char which let the mask used in ^

Re: mount_smbfs gives error when stored crypted pw is used

2017-06-07 Thread Matthias Apitz
pos; char *dp; printf("smb_simplecrypt(): pw: [%s]\n", src); if (dst == NULL) { dst = malloc(4 + 2 * strlen(src)); if (dst == NULL) return NULL; } dp = dst; *dst++ = '$'; *dst++ = '$';

Re: mount_smbfs gives error when stored crypted pw is used

2017-06-06 Thread Matthias Apitz
st password change of the domain pw we have todo > every 12 weeks or so. > > Now the new crypted and stored pw from /etc/nsmb.conf is not accepted > anymore. In detail, when I do: > > ... I looked into the sources in src/contrib/smbfs/lib/smb to understand how the hashed pw is transl

Re: pw: pw: Invalid min_uid: '2000'; ignoring

2015-08-21 Thread Baptiste Daroussin
On Fri, Aug 21, 2015 at 03:48:13PM +0200, O. Hartmann wrote: Setting up on NanoBSD vi pw command an initial /etc/pw.conf (usermod -D), I use amongst other options also: -u 2000,32767 -i 2000,32767 which finally and successfully expands to [...] # Range of valid default user ids

pw: pw: Invalid min_uid: '2000'; ignoring

2015-08-21 Thread O. Hartmann
Setting up on NanoBSD vi pw command an initial /etc/pw.conf (usermod -D), I use amongst other options also: -u 2000,32767 -i 2000,32767 which finally and successfully expands to [...] # Range of valid default user ids minuid = 2000 maxuid = 32767 # Range of valid default group ids mingid

Re: pw: pw: Invalid min_uid: '2000'; ignoring

2015-08-21 Thread Baptiste Daroussin
On Fri, Aug 21, 2015 at 04:13:00PM +0200, Baptiste Daroussin wrote: On Fri, Aug 21, 2015 at 03:48:13PM +0200, O. Hartmann wrote: Setting up on NanoBSD vi pw command an initial /etc/pw.conf (usermod -D), I use amongst other options also: -u 2000,32767 -i 2000,32767 which finally

pw after r284118 not execute -V

2015-06-13 Thread Andrey Fesenko
Hello, /usr/sbin/pw useradd -n user -s /bin/csh -g wheel -w yes -V /usr/obj/_.mount.freebsd/etc/ -d /usr/home/user make not user with /usr/obj/_.mount.freebsd/etc/ but creates it in the main system /etc ___ freebsd-current@freebsd.org mailing list http

Re: pw is broken?

2013-03-09 Thread hiren panchasara
On Mar 8, 2013 9:44 PM, KT Sin kt...@acm.org wrote: pw is crashing with seg fault due to this change? http://svnweb.freebsd.org/base/head/lib/libutil/gr_util.c?r1=245390r2=247919 I think the correct fix is committed with: http://svnweb.freebsd.org/changeset/base/248102 Hiren # gdb ./pw

Re: pw is broken?

2013-03-09 Thread Hartmann, O.
Am 03/09/13 15:34, schrieb hiren panchasara: On Mar 8, 2013 9:44 PM, KT Sin kt...@acm.org wrote: pw is crashing with seg fault due to this change? http://svnweb.freebsd.org/base/head/lib/libutil/gr_util.c?r1=245390r2=247919 I think the correct fix is committed with: http

Re: pw is broken?

2013-03-09 Thread KT Sin
saw the commit an hour ago. rebuilt libutil.so.9 and unfortunately it still crashes for me :( --- On Sat, 3/9/13, hiren panchasara hiren.panchas...@gmail.com wrote: From: hiren panchasara hiren.panchas...@gmail.com Subject: Re: pw is broken? To: kt...@acm.org Cc: freebsd-current freebsd-current

Re: pw is broken?

2013-03-09 Thread Andreas Tobler
On 09.03.13 15:52, Hartmann, O. wrote: Am 03/09/13 15:34, schrieb hiren panchasara: On Mar 8, 2013 9:44 PM, KT Sin kt...@acm.org wrote: pw is crashing with seg fault due to this change? http://svnweb.freebsd.org/base/head/lib/libutil/gr_util.c?r1=245390r2=247919 I think the correct fix

Re: pw is broken?

2013-03-09 Thread KT Sin
ah, this is a different problem. one quick workaround is to comment out the unused variable ic :P, or you could include INVARIANTS in your kernel config, or you could ping adrian :) --- On Sat, 3/9/13, Hartmann, O. ohart...@zedat.fu-berlin.de wrote: But neither r248102 nor r248103 compile!

Re: pw is broken?

2013-03-09 Thread KT Sin
ah. my apologies. rebuilt the new libutil again and it seems that r248012 does indeed resolve the problem. :) --- On Sat, 3/9/13, KT Sin kt...@acm.org wrote: From: KT Sin kt...@acm.org Subject: Re: pw is broken? To: hiren panchasara hiren.panchas...@gmail.com, d...@freebsd.org Cc: freebsd

pw is broken?

2013-03-08 Thread KT Sin
pw is crashing with seg fault due to this change? http://svnweb.freebsd.org/base/head/lib/libutil/gr_util.c?r1=245390r2=247919 # gdb ./pw GNU gdb 6.1.1 [FreeBSD] Copyright 2004 Free Software Foundation, Inc. GDB is free software, covered by the GNU General Public License, and you are welcome

Re: pw keeps setting /etc/group to 0600

2012-11-30 Thread matt
On 11/17/12 07:24, Ryan Stone wrote: /etc/group is supposed to be world-reable, right? Tools like groups or pw groupshow certainly seem to think so: [rstone@rstone-server ~]groups 1001 920 [rstone@rstone-server ~]ls -l /etc/group -rw--- 1 root 0 482 Nov 14 21:02 /etc/group [rstone

Re: pw keeps setting /etc/group to 0600

2012-11-21 Thread Jaakko Heinonen
On 2012-11-19, Mateusz Guzik wrote: First, pw should not fail if other instance is running, it should wait instead (think of parallel batch scripts adding some users/groups). Second, current code has a race: lockfd = open(group_file, O_RDONLY, 0); if (lockfd 0 || fcntl(lockfd, F_SETFD, 1

Re: pw keeps setting /etc/group to 0600

2012-11-21 Thread Mateusz Guzik
On Wed, Nov 21, 2012 at 05:45:43PM +0200, Jaakko Heinonen wrote: On 2012-11-19, Mateusz Guzik wrote: First, pw should not fail if other instance is running, it should wait instead (think of parallel batch scripts adding some users/groups). Second, current code has a race: lockfd = open

Re: pw keeps setting /etc/group to 0600

2012-11-19 Thread Mateusz Guzik
On Sat, Nov 17, 2012 at 11:20:21AM -0500, Ryan Stone wrote: My original complaint that /etc/group gets permissions of 0600 is a result of a bug in libutil, which bapt@ ported pw to use in r242349. The new group manipulation API using mktemp to create a temporary file, writes the new group

Re: pw keeps setting /etc/group to 0600

2012-11-19 Thread Baptiste Daroussin
On Mon, Nov 19, 2012 at 11:28:43PM +0100, Mateusz Guzik wrote: On Sat, Nov 17, 2012 at 11:20:21AM -0500, Ryan Stone wrote: My original complaint that /etc/group gets permissions of 0600 is a result of a bug in libutil, which bapt@ ported pw to use in r242349. The new group manipulation API

Re: pw keeps setting /etc/group to 0600

2012-11-19 Thread Baptiste Daroussin
, which bapt@ ported pw to use in r242349. The new group manipulation API using mktemp to create a temporary file, writes the new group database to the temp file and then renames the temp file to /etc/group. The problem here is that mktemp creates a file with a mode of 600, and libutil

pw keeps setting /etc/group to 0600

2012-11-17 Thread Ryan Stone
/etc/group is supposed to be world-reable, right? Tools like groups or pw groupshow certainly seem to think so: [rstone@rstone-server ~]groups 1001 920 [rstone@rstone-server ~]ls -l /etc/group -rw--- 1 root 0 482 Nov 14 21:02 /etc/group [rstone@rstone-server ~]sudo chmod a+r /etc/group

Re: pw keeps setting /etc/group to 0600

2012-11-17 Thread Ryan Stone
Wow. So apparently things are even more broken than I though. Let's play, What group am I in? root@group-testing:/usr/home/rstone # cd /tmp root@group-testing:/tmp # pw groupadd testing root@group-testing:/tmp # mkdir testdir root@group-testing:/tmp # chown root:testing testdir/ root@group

Re: pw keeps setting /etc/group to 0600

2012-11-17 Thread Mateusz Guzik
On Sat, Nov 17, 2012 at 11:20:21AM -0500, Ryan Stone wrote: Wow. So apparently things are even more broken than I though. Let's play, What group am I in? root@group-testing:/usr/home/rstone # cd /tmp root@group-testing:/tmp # pw groupadd testing root@group-testing:/tmp # mkdir testdir

[CFT] pw(8) using pw/gr API from libutil

2012-02-09 Thread Baptiste Daroussin
Hi all, I have been modifying pw(8) it order for it to user the pw_* and gr_* function from libutil, to: avoid code duplication have a single API to manipulate user/group things. I have been using this version for a while now and it works quite well to me, I'm just missing testing in real NIS

Changes to pw/pw_user.c

2003-01-25 Thread Garance A Drosihn
, there! Can we enable using '$' in usernames in pw? The patch is attached. Other variant is to enable using '$' only at end of user name. Here is a patch which allows a '$' as the last character of a userid or a group name. Technically this is based on a patch that Terry Lambert wrote

pw

2003-01-23 Thread Max Khon
hi, there! Can we enable using '$' in usernames in pw? The patch is attached. Other variant is to enable using '$' only at end of user name. /fjoe Index: pw_user.c === RCS file: /home/ncvs/src/usr.sbin/pw/pw_user.c,v retrieving

Re: pw

2003-01-23 Thread Craig Rodrigues
On Fri, Jan 24, 2003 at 02:25:38AM +0600, Max Khon wrote: hi, there! Can we enable using '$' in usernames in pw? The patch is attached. The same patch was submitted here by David Chapman: http://www.freebsd.org/cgi/getmsg.cgi?fetch=1059329+1062195+/usr/local/www/db/text/2002/freebsd-current

Re: pw

2003-01-23 Thread Max Khon
hi, there! On Thu, Jan 23, 2003 at 03:54:18PM -0500, Craig Rodrigues wrote: Can we enable using '$' in usernames in pw? The patch is attached. The same patch was submitted here by David Chapman: http://www.freebsd.org/cgi/getmsg.cgi?fetch=1059329+1062195+/usr/local/www/db/text/2002

Re: pw

2003-01-23 Thread Terry Lambert
Max Khon wrote: most messages were related to adduser.pl. adduser.pl has gone and adduser.sh now uses pw directly as for login class and group names -- there is nothing wrong with '$' in them but if anyone would be uncomfortable with it why not commit the patch that someone (Terry

Re: pw

2003-01-23 Thread Mike Makonnen
doesn't object I say go for it! Cheers. -- Mike Makonnen | GPG-KEY: http://www.identd.net/~mtm/mtm.asc [EMAIL PROTECTED] | Fingerprint: D228 1A6F C64E 120A A1C9 A3AA DAE1 E2AF DBCC 68B9 Index: usr.sbin/pw/pw.h === RCS file: /home/ncvs

Re: pw

2003-01-23 Thread Garance A Drosihn
At 2:25 AM +0600 1/24/03, Max Khon wrote: hi, there! Can we enable using '$' in usernames in pw? The patch is attached. Other variant is to enable using '$' only at end of user name. I'd prefer to go with only at the end of a user name, and I did have a patch which does that. Now I just have

Re: pw group add problem

2001-08-30 Thread Dima Dorfman
David W. Chapman Jr. [EMAIL PROTECTED] wrote: When I run the command in the topic I get the following error. pw: group update: Inappropriate ioctl for device This works in -stable I noticed this problem while testing postfix-current which runs /usr/sbin/pw groupadd ${group} -h

pw group add problem

2001-08-29 Thread David W. Chapman Jr.
When I run the command in the topic I get the following error. pw: group update: Inappropriate ioctl for device This works in -stable I noticed this problem while testing postfix-current which runs /usr/sbin/pw groupadd ${group} -h - || exit from pkg-install and also gives the above error

Re: The pw command

2000-03-10 Thread Paul Richards
Kris Kennaway wrote: On Fri, 10 Mar 2000, Paul Richards wrote: Non-root users can use the pw command to get information from the master.passwd file e.g. ps showuser paul paul:*:1000:1000::0:0: Richards:/home/paul:/usr/local/bin/bash % pw showuser kkenn kkenn:*:1000:0::0:0

Re: The pw command

2000-03-10 Thread Kris Kennaway
On Fri, 10 Mar 2000, Paul Richards wrote: So what I'm puzzled about now is how come yours is different and do we think its correct that pwd.db and /etc/passwd have different information in them? Oops, that was a cut-n-paste-o. I didn't notice the extra two fields the second time :-) It's

The pw command

2000-03-09 Thread Paul Richards
Non-root users can use the pw command to get information from the master.passwd file e.g. ps showuser paul paul:*:1000:1000::0:0: Richards:/home/paul:/usr/local/bin/bash which shows the class, password expiry and account expiry. I'm not sure whether that's information that should be kept secure

RE: The pw command

2000-03-09 Thread Mike Heffner
On 10-Mar-2000 Paul Richards wrote: | Non-root users can use the pw command to get information from the | master.passwd file e.g. | | ps showuser paul | paul:*:1000:1000::0:0: Richards:/home/paul:/usr/local/bin/bash | | which shows the class, password expiry and account expiry

Re: The pw command

2000-03-09 Thread Kris Kennaway
On Fri, 10 Mar 2000, Paul Richards wrote: Non-root users can use the pw command to get information from the master.passwd file e.g. ps showuser paul paul:*:1000:1000::0:0: Richards:/home/paul:/usr/local/bin/bash % pw showuser kkenn kkenn:*:1000:0::0:0:Kris Kennaway:/home/kkenn:/usr/local