🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: news.admin.peering
Article #1626

Re: Newbie question

#1626
From: Julien ÉLIE
Date: Tue, 11 Apr 2023 10:12
47 lines
2797 bytes
Hi Eli,

> The nnrpd manual states:
> 
> "As each command is received, nnrpd tries to change its "argv" array so that
> ps(1) will print out the command being executed."
> 
> This will then look like this:
> nnrpd: <xxx.xxx.xxx.xxx> GROUP
> nnrpd: <xxx.xxx.xxx.xxx> XOVER
> 
> Is it perhaps also possible to add the authenticated user to this?
> 
> Something like:
> nnrpd: <xxx.xxx.xxx.xxx> Eli GROUP
> nnrpd: <xxx.xxx.xxx.xxx> Eli XOVER
> 
> This would make it possible to limit the number of connections per user via a
> perl script.

It is indeed possible to use that "feature".

If you can rebuild INN from sources, just change the following command 
in nnrpd/nnrpd.c:

-        setproctitle("%s %s", Client.host, av[0]);
+
+        setproctitle("%s %s %s", Client.host,
+                     PERMuser[0] != '\0' ? PERMuser : "-", av[0]);


I then have lines like that in a ps output:

   nnrpd: accepting connections
   nnrpd: 176-143-2-105.abo.bbox.fr julien GROUP
   nnrpd: 5.14.145.68 <all> LIST


I am unsure if this would be worth having in an official release; there 
may be privacy concerns.  Maybe it should be configurable with a 
readers.conf option (like addprocesstitleuser which would enable that 
behaviour when set to true in an access group).

-- 
Julien ÉLIE

« Et maintenant, la balle est dans le camp des slalomeurs. »
Technical Details
Message-ID: <u13bps$188ar$4@news.trigofacile.com>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!apf1.newsdeef.eu!not-for-mail
References: <sXMOL.4024495$MJk2.1098149@fx06.ams4> <tvfr7u$1ua8$2@news.trigofacile.com> <evKSL.4136913$SIb3.775609@fx05.ams4> <tvft64$240m$1@news.trigofacile.com> <jjVXL.4378630$vSy3.384664@fx04.ams4>

Show Full Headers
Complete Article Headers
Message-ID: <u13bps$188ar$4@news.trigofacile.com>
Subject: Re: Newbie question
Date: Tue, 11 Apr 2023 12:12:12 +0200
From: Julien ÉLIE <iulius@nom-de-mon-site.com.invalid>
References: <sXMOL.4024495$MJk2.1098149@fx06.ams4> <tvfr7u$1ua8$2@news.trigofacile.com> <evKSL.4136913$SIb3.775609@fx05.ams4> <tvft64$240m$1@news.trigofacile.com> <jjVXL.4378630$vSy3.384664@fx04.ams4>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!apf1.newsdeef.eu!not-for-mail
Newsgroups: news.admin.peering
Organization: Groupes francophones par TrigoFACILE
Mime-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 8bit
Injection-Date: Tue, 11 Apr 2023 10:12:12 -0000 (UTC)
Injection-Info: news.trigofacile.com; posting-account="julien"; posting-host="san13-h02-176-143-2-105.dsl.sta.abo.bbox.fr:176.143.2.105"; logging-data="1319259"; mail-complaints-to="abuse@trigofacile.com"
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:102.0) Gecko/20100101 Thunderbird/102.9.1
Cancel-Lock: sha1:tmx2/sHWWzxEebeMGTooybf210M= sha256:t/Z3n2OFU2v06sBeSLl64pKsyrwjMQbr7BU8TsvkO2g= sha1:z7JFt94MJha6MzQKnIVu92t3GMg= sha256:D181638T2LMAee44zN7AESgwKxFjq2CgQNyxC1EaML0=
In-Reply-To: <jjVXL.4378630$vSy3.384664@fx04.ams4>