Debian Bug report logs - #383296
manpages: nlmsg_pid/nl_pid is *not* the process ID

version graph

Package: manpages; Maintainer for manpages is Martin Schulze <joey@debian.org>; Source for manpages is src:manpages.

Reported by: <herbert@gondor.apana.org.au>

Date: Wed, 16 Aug 2006 12:33:06 UTC

Severity: wishlist

Tags: fixed-upstream, upstream

Found in version manpages/1.70-1

Fixed in version manpages/3.42-1

Done: Simon Paillard <spaillard@debian.org>

Bug is archived. No further changes may be made.

Forwarded to linux-man@vger.kernel.org

Toggle useless messages

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to debian-bugs-dist@lists.debian.org, Martin Schulze <joey@debian.org>:
Bug#383296; Package manpages. Full text and rfc822 format available.

Acknowledgement sent to <herbert@gondor.apana.org.au>:
New Bug report received and forwarded. Copy sent to Martin Schulze <joey@debian.org>. Full text and rfc822 format available.

Message #5 received at submit@bugs.debian.org (full text, mbox):

From: <herbert@gondor.apana.org.au>
To: submit@bugs.debian.org
Subject: manpages: nlmsg_pid/nl_pid is *not* the process ID
Date: Wed, 16 Aug 2006 22:01:09 +1000
Package: manpages
Version: 1.70-1
Severity: normal

The man page netlink(7) refers to nlmsg_pid and nl_pid as process IDs.
This is completely incorrect.  Treating them as process IDs can lead
to security holes.  So please ask upstream to correct this as soon as
possible.

Thanks,

-- System Information
Debian Release: 3.1
Kernel Version: Linux gondolin 2.6.17-rc4 #1 SMP PREEMPT Wed May 17 17:28:00 EST 2006 i686 GNU/Linux




Information forwarded to debian-bugs-dist@lists.debian.org, Martin Schulze <joey@debian.org>:
Bug#383296; Package manpages. Full text and rfc822 format available.

Acknowledgement sent to Michael Kerrisk <mtk-manpages@gmx.net>:
Extra info received and forwarded to list. Copy sent to Martin Schulze <joey@debian.org>. Full text and rfc822 format available.

Message #10 received at 383296@bugs.debian.org (full text, mbox):

From: Michael Kerrisk <mtk-manpages@gmx.net>
To: herbert@gondor.apana.org.au, 383296@bugs.debian.org
Subject: Re: Bug#383296: manpages: nlmsg_pid/nl_pid is *not* the process ID
Date: Tue, 26 Sep 2006 14:19:32 +0200

herbert@gondor.apana.org.au wrote:
> Package: manpages
> Version: 1.70-1
> Severity: normal
> 
> The man page netlink(7) refers to nlmsg_pid and nl_pid as process IDs.
> This is completely incorrect.  Treating them as process IDs can lead
> to security holes.  So please ask upstream to correct this as soon as
> possible.

Hello Herbert

Can you provide a patch with the sort of wording you think is correct?

Thanks

Michael



Information forwarded to debian-bugs-dist@lists.debian.org, Martin Schulze <joey@debian.org>:
Bug#383296; Package manpages. Full text and rfc822 format available.

Acknowledgement sent to Herbert Xu <herbert@gondor.apana.org.au>:
Extra info received and forwarded to list. Copy sent to Martin Schulze <joey@debian.org>. Full text and rfc822 format available.

Message #15 received at 383296@bugs.debian.org (full text, mbox):

From: Herbert Xu <herbert@gondor.apana.org.au>
To: Michael Kerrisk <mtk-manpages@gmx.net>
Cc: 383296@bugs.debian.org
Subject: Re: Bug#383296: manpages: nlmsg_pid/nl_pid is *not* the process ID
Date: Wed, 27 Sep 2006 01:21:28 +1000
On Tue, Sep 26, 2006 at 02:19:32PM +0200, Michael Kerrisk wrote:
>
> > The man page netlink(7) refers to nlmsg_pid and nl_pid as process IDs.
> > This is completely incorrect.  Treating them as process IDs can lead
> > to security holes.  So please ask upstream to correct this as soon as
> > possible.
> 
> Can you provide a patch with the sort of wording you think is correct?

The point is that these fields are simply opaque values that identify
a specific netlink socket.  So please refer to them as the netlink
socket address.

Cheers,
-- 
Visit Openswan at http://www.openswan.org/
Email: Herbert Xu ~{PmV>HI~} <herbert@gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt



Information forwarded to debian-bugs-dist@lists.debian.org, Martin Schulze <joey@debian.org>:
Bug#383296; Package manpages. Full text and rfc822 format available.

Acknowledgement sent to Martin Schulze <joey@infodrom.org>:
Extra info received and forwarded to list. Copy sent to Martin Schulze <joey@debian.org>. Full text and rfc822 format available.

Message #20 received at 383296@bugs.debian.org (full text, mbox):

From: Martin Schulze <joey@infodrom.org>
To: Herbert Xu <herbert@gondor.apana.org.au>
Cc: Michael Kerrisk <mtk-manpages@gmx.net>, 383296@bugs.debian.org
Subject: Re: Bug#383296: manpages: nlmsg_pid/nl_pid is *not* the process ID
Date: Wed, 25 Apr 2007 17:29:20 +0200
Herbert Xu wrote:
> On Tue, Sep 26, 2006 at 02:19:32PM +0200, Michael Kerrisk wrote:
> >
> > > The man page netlink(7) refers to nlmsg_pid and nl_pid as process IDs.
> > > This is completely incorrect.  Treating them as process IDs can lead
> > > to security holes.  So please ask upstream to correct this as soon as
> > > possible.
> > 
> > Can you provide a patch with the sort of wording you think is correct?
> 
> The point is that these fields are simply opaque values that identify
> a specific netlink socket.  So please refer to them as the netlink
> socket address.

The kernel header of 2.6.20 says in include/linux/netlink.h

/* Sending process PID */

If it should be changed in the corresponding manpage, I guess that it should
be changed in the kernel as well (if not first).

Apart from that, the manpage netlink(7) contains the following note:

       nlmsg_seq  and  nlmsg_pid  are used to track messages.  nlmsg_pid shows
       the origin of the message.  Note that there isn't  a  1:1  relationship
       between  nlmsg_pid and the PID of the process if the message originated
       from a netlink socket.  See the ADDRESS  FORMATS  section  for  further
       information.

which explains that's nlmsg_pid is not exactly a process ID.

Could you propose an improved text instead.

Regards,

	Joey

-- 
Given enough thrust pigs will fly, but it's not necessarily a good idea.

Please always Cc to me when replying to me on the lists.



Severity set to `wishlist' from `normal' Request was from Martin Schulze <joey@infodrom.org> to control@bugs.debian.org. (Wed, 25 Apr 2007 15:39:09 GMT) Full text and rfc822 format available.

Tags added: help, moreinfo Request was from Martin Schulze <joey@infodrom.org> to control@bugs.debian.org. (Wed, 25 Apr 2007 15:39:10 GMT) Full text and rfc822 format available.

Information forwarded to debian-bugs-dist@lists.debian.org, Martin Schulze <joey@debian.org>:
Bug#383296; Package manpages. Full text and rfc822 format available.

Acknowledgement sent to Herbert Xu <herbert@gondor.apana.org.au>:
Extra info received and forwarded to list. Copy sent to Martin Schulze <joey@debian.org>. Full text and rfc822 format available.

Message #29 received at 383296@bugs.debian.org (full text, mbox):

From: Herbert Xu <herbert@gondor.apana.org.au>
To: Martin Schulze <joey@infodrom.org>
Cc: Michael Kerrisk <mtk-manpages@gmx.net>, 383296@bugs.debian.org
Subject: Re: Bug#383296: manpages: nlmsg_pid/nl_pid is *not* the process ID
Date: Sat, 5 May 2007 16:01:05 +1000
On Wed, Apr 25, 2007 at 05:29:20PM +0200, Martin Schulze wrote:
> 
> The kernel header of 2.6.20 says in include/linux/netlink.h
> 
> /* Sending process PID */
> 
> If it should be changed in the corresponding manpage, I guess that it should
> be changed in the kernel as well (if not first).

Thanks for pointing that out.  I've made a patch to fix that.

> Apart from that, the manpage netlink(7) contains the following note:
> 
>        nlmsg_seq  and  nlmsg_pid  are used to track messages.  nlmsg_pid shows
>        the origin of the message.  Note that there isn't  a  1:1  relationship
>        between  nlmsg_pid and the PID of the process if the message originated
>        from a netlink socket.  See the ADDRESS  FORMATS  section  for  further
>        information.
> 
> which explains that's nlmsg_pid is not exactly a process ID.

We should simply call these numbers port IDs and remove all references
to the word process.

Cheers,
-- 
Visit Openswan at http://www.openswan.org/
Email: Herbert Xu ~{PmV>HI~} <herbert@gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt



Information forwarded to debian-bugs-dist@lists.debian.org, Martin Schulze <joey@debian.org>:
Bug#383296; Package manpages. (Mon, 23 Jul 2012 23:06:06 GMT) Full text and rfc822 format available.

Acknowledgement sent to Simon Paillard <spaillard@debian.org>:
Extra info received and forwarded to list. Copy sent to Martin Schulze <joey@debian.org>. (Mon, 23 Jul 2012 23:06:06 GMT) Full text and rfc822 format available.

Message #34 received at 383296@bugs.debian.org (full text, mbox):

From: Simon Paillard <spaillard@debian.org>
To: 383296@bugs.debian.org
Cc: "Michael Kerrisk (man-pages)" <mtk.manpages@gmail.com>
Subject: Re: Bug#383296: manpages: nlmsg_pid/nl_pid is *not* the process ID
Date: Tue, 24 Jul 2012 01:03:26 +0200
forwarded 383296 linux-man@vger.kernel.org
thanks

On Sat, May 05, 2007 at 04:01:05PM +1000, Herbert Xu wrote:
> On Wed, Apr 25, 2007 at 05:29:20PM +0200, Martin Schulze wrote:
> > 
> > The kernel header of 2.6.20 says in include/linux/netlink.h
> > 
> > /* Sending process PID */
> > 
> > If it should be changed in the corresponding manpage, I guess that it should
> > be changed in the kernel as well (if not first).
> 
> Thanks for pointing that out.  I've made a patch to fix that.

Applied some years ago:
http://git.kernel.org/?p=linux/kernel/git/torvalds/linux.git;a=commitdiff;h=cf130cb102487723bdfc53e4abde1227a7563797

> > Apart from that, the manpage netlink(7) contains the following note:
> > 
> >        nlmsg_seq  and  nlmsg_pid  are used to track messages.  nlmsg_pid shows
> >        the origin of the message.  Note that there isn't  a  1:1  relationship
> >        between  nlmsg_pid and the PID of the process if the message originated
> >        from a netlink socket.  See the ADDRESS  FORMATS  section  for  further
> >        information.
> > 
> > which explains that's nlmsg_pid is not exactly a process ID.
> 
> We should simply call these numbers port IDs and remove all references
> to the word process.

Trivial fix sent upstream to update struct comments, not sure how
Michael wants to update the wording around.

-- 
Simon Paillard



Removed tag(s) help and moreinfo. Request was from Simon Paillard <spaillard@debian.org> to control@bugs.debian.org. (Mon, 23 Jul 2012 23:06:08 GMT) Full text and rfc822 format available.

Added tag(s) upstream. Request was from Simon Paillard <spaillard@debian.org> to control@bugs.debian.org. (Mon, 23 Jul 2012 23:06:09 GMT) Full text and rfc822 format available.

Set Bug forwarded-to-address to 'linux-man@vger.kernel.org'. Request was from Simon Paillard <spaillard@debian.org> to control@bugs.debian.org. (Mon, 23 Jul 2012 23:09:07 GMT) Full text and rfc822 format available.

Information forwarded to debian-bugs-dist@lists.debian.org, Martin Schulze <joey@debian.org>:
Bug#383296; Package manpages. (Sat, 28 Jul 2012 16:12:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to mtk.manpages@gmail.com:
Extra info received and forwarded to list. Copy sent to Martin Schulze <joey@debian.org>. (Sat, 28 Jul 2012 16:12:02 GMT) Full text and rfc822 format available.

Message #45 received at 383296@bugs.debian.org (full text, mbox):

From: "Michael Kerrisk (man-pages)" <mtk.manpages@gmail.com>
To: Simon Paillard <spaillard@debian.org>
Cc: 383296@bugs.debian.org
Subject: Re: Bug#383296: manpages: nlmsg_pid/nl_pid is *not* the process ID
Date: Sat, 28 Jul 2012 18:09:25 +0200
tags 383296 fixed-upstream
thanks

I've applied the patch below. Will be in upstream 3.42.

Thanks,

Michael

--- a/man7/netlink.7
+++ b/man7/netlink.7
@@ -4,7 +4,7 @@
 .\" Based on the original comments from Alexey Kuznetsov
 .\" Modified 2005-12-27 by Hasso Tepper <hasso@estpak.ee>
 .\" $Id: netlink.7,v 1.8 2000/06/22 13:23:00 ak Exp $
-.TH NETLINK  7 2012-04-14 "Linux" "Linux Programmer's Manual"
+.TH NETLINK  7 2012-07-28 "Linux" "Linux Programmer's Manual"
 .SH NAME
 netlink \- Communication between kernel and userspace (AF_NETLINK)
 .SH SYNOPSIS
@@ -139,7 +139,7 @@ struct nlmsghdr {
     __u16 nlmsg_type;   /* Type of message content. */
     __u16 nlmsg_flags;  /* Additional flags. */
     __u32 nlmsg_seq;    /* Sequence number. */
-    __u32 nlmsg_pid;    /* PID of the sending process. */
+    __u32 nlmsg_pid;    /* Sender port ID. */
 };
 .fi
 .in
@@ -291,7 +291,7 @@ not equal 0).
 struct sockaddr_nl {
     sa_family_t     nl_family;  /* AF_NETLINK */
     unsigned short  nl_pad;     /* Zero. */
-    pid_t           nl_pid;     /* Process ID. */
+    pid_t           nl_pid;     /* Port ID. */
     __u32           nl_groups;  /* Multicast groups mask. */
 };
 .fi



Added tag(s) fixed-upstream. Request was from Simon Paillard <spaillard@debian.org> to control@bugs.debian.org. (Thu, 23 Aug 2012 19:57:05 GMT) Full text and rfc822 format available.

Added tag(s) pending. Request was from Simon Paillard <spaillard@debian.org> to control@bugs.debian.org. (Sat, 25 Aug 2012 14:57:05 GMT) Full text and rfc822 format available.

Reply sent to Simon Paillard <spaillard@debian.org>:
You have taken responsibility. (Sat, 25 Aug 2012 16:21:06 GMT) Full text and rfc822 format available.

Notification sent to <herbert@gondor.apana.org.au>:
Bug acknowledged by developer. (Sat, 25 Aug 2012 16:21:06 GMT) Full text and rfc822 format available.

Message #54 received at 383296-close@bugs.debian.org (full text, mbox):

From: Simon Paillard <spaillard@debian.org>
To: 383296-close@bugs.debian.org
Subject: Bug#383296: fixed in manpages 3.42-1
Date: Sat, 25 Aug 2012 16:17:41 +0000
Source: manpages
Source-Version: 3.42-1

We believe that the bug you reported is fixed in the latest version of
manpages, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to 383296@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Simon Paillard <spaillard@debian.org> (supplier of updated manpages package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmaster@debian.org)


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Format: 1.8
Date: Thu, 23 Aug 2012 21:50:38 +0200
Source: manpages
Binary: manpages manpages-dev
Architecture: source all
Version: 3.42-1
Distribution: unstable
Urgency: low
Maintainer: Martin Schulze <joey@debian.org>
Changed-By: Simon Paillard <spaillard@debian.org>
Description: 
 manpages   - Manual pages about using a GNU/Linux system
 manpages-dev - Manual pages about using GNU/Linux for development
Closes: 383296 526778 538641 609033 660479 671514 671515 673436 673873 673875 674051 679498
Changes: 
 manpages (3.42-1) unstable; urgency=low
 .
   [ Simon Paillard ]
   * Add myself to Uploaders
   * Imported Upstream version 3.42:
     . new manpages: get_robust_list.2 mallinfo.3 malloc_info.3 malloc_stats.3
     . remove outdated links: path_resolution.2 epoll.4 fifo.4 futex.4
       complex.5 environ.5
     . Fix repeated word in memchr.3 (Closes: #679498)
     . isgreater.3: arguments must be real-floating (Closes: #609033)
     . utf-8.7: clarifications (Closes: #538641)
     . getaddrinfo.3: note that AI_ADDRCONFIG is not affected by loopback
       addresses (Closes: #660479)
     . Fix "rtnetlink(7): Line in table too long" (Closes: #674051)
     . Fix "netlink(7): Line in table is too long" (Closes: #673875)
     . Fix "netdevice(7): Line in table too long" (Closes: #673873)
     . Fix "suffixes(7): Warnings from "grotty"" (Closes: #673436)
     . Fix "ioctl_list(2): table wider than line width" (Closes: #671515)
     . Fix groff warnings console_codes(4) (Closes: #671514)
     . netlink.7: *_pid fields are not process but port id (Closes: #383296)
   * Drop obsolete formatting patch: gettimeofday.2 wprintf.3 setnetgrent.3
   * Drop patch getgid.2, getuid.2: now documented by upstream credentials(7)
   * Drop inconsistent coding style patch: bsearch.3 qsort.3
   * iconv.3: remove Debian patch, accepted upstream and moved to NOTES
   * Remove old links added 10y ago due to debian specific man-db
   * fclose.3: drop debian patches, mark the remaining as rejected upstream
   * Remove mallinfo.3 from missing.7, added in upstream 3.41
   * Drop outdated debian/readme
   * getifaddrs.3, rtnetlink.7: stats interface is struct rtnl_link_stats, not
     net_device_stats (Closes: #526778) - thanks to Julien Cristau
Checksums-Sha1: 
 adc626704fe11d2d1ee87264e6ffd82b01424448 1904 manpages_3.42-1.dsc
 ca33acaa9708ea04d659ada3e49a2b808ade03dc 1748638 manpages_3.42.orig.tar.gz
 78f668751bc17c5ec2d6eb9f9f4e0c45581bcc1c 46466 manpages_3.42-1.diff.gz
 35199833a71faeb1d1d02210309ac61c8ec52adc 784438 manpages_3.42-1_all.deb
 29def2ec668e3b6d4f746e56793501e3171c3c99 1728792 manpages-dev_3.42-1_all.deb
Checksums-Sha256: 
 ba83353d9cabacd1978261d4763b7665f428b4f02f1bb16e27e6994126831b5f 1904 manpages_3.42-1.dsc
 e366548e907776780d8558d9ab2918d49c28b7f9f926a4bdbe8559cc27165a1d 1748638 manpages_3.42.orig.tar.gz
 d5d96fc20ef2192af599b57a174e510b9868a0ff718662034dfceb4907835e68 46466 manpages_3.42-1.diff.gz
 dbd074db50d0086168e0c1df6a0d2bbf0ff396bdf6ebc20d41ee814f4ab1c3e3 784438 manpages_3.42-1_all.deb
 b0b0bef7ac02ef1bb314856db094c85a33a53f40e3601c1080ec21738d865443 1728792 manpages-dev_3.42-1_all.deb
Files: 
 87240352356f2dc73d8834a9c16365e6 1904 doc important manpages_3.42-1.dsc
 cc8f73ecd8a123ceb7a8670daa91ee6c 1748638 doc important manpages_3.42.orig.tar.gz
 94b82badf5d39c826aa728c7e57f3d9f 46466 doc important manpages_3.42-1.diff.gz
 c96c0a4dfcfef21a1dbae4f982fe0816 784438 doc important manpages_3.42-1_all.deb
 b1ff58b81d31410b5593ee97d4617f67 1728792 doc optional manpages-dev_3.42-1_all.deb

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.12 (GNU/Linux)

iQIcBAEBCAAGBQJQOPbyAAoJEN/3OMLRbPuie3gP/RGCk7GsGOIW2jQagjv48WfY
nCb5winm4kaYS4SLf501J9BiIpghDMOntXwL4X7Er8NtV7adbcwr4VawW+BSTDnh
aEiQM9AFkpK2FIKBP2YWwVhqsl4VIEg/fezziRt4dK5b8MPNJLPk74mQ+1MJUG0L
Zb+oMtnwqBFKjb2xU1glNaQ01YUYsLnhZY8n1D+rDVfRRqfFzIiDvVJYdSKU1iwT
T61AYkNfjjIYG91jxjUi7Xi2cQudKqvOMUL0Cz/349A+9b8tMmLPvhjf8coRBOVS
3x7J3skD+npiT5DT9MUswKhwmy8Ml5JSr8JgdJu/zQRcnvWGP3FS6dDHkMRXGgtK
+kHp7yMfiMsmMqQqIjjYzhPRW/xQZslBjNlsCMSbI4VuMArn+hezqb4rfzfHe8yv
kOmeaH8svVEJ2eRbV+YbBglXXsQOeBKLAFWqrdLvVXXmCTuPFprPxsP/OGvQ+i2m
KWRsKzReMQ7nV31xCga9NxENou6v1EnF+sEVi1eBWYWH7lJWwcoYnAnHYHc6UsyA
2hcTw4nwxZCkMTXG/PewYd4OISJ3ChlkCC3yZ7U1dpFQisvgnhjNiROxBfKf2T4x
f1dfpNIfWf0i/ynn9I5QRSbN+ZNhyx0Txc4jiftJt/Dv7kqtU7hYuRje56pdoiC9
EV+YSyJky+x4+NLXJfhB
=ljey
-----END PGP SIGNATURE-----




Bug archived. Request was from Debbugs Internal Request <owner@bugs.debian.org> to internal_control@bugs.debian.org. (Sun, 14 Oct 2012 07:28:33 GMT) Full text and rfc822 format available.

Send a report that this bug log contains spam.


Debian bug tracking system administrator <owner@bugs.debian.org>. Last modified: Fri Apr 18 14:26:48 2014; Machine Name: buxtehude.debian.org

Debian Bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.