On Thu, 25 Nov 2004, Martin Pitt wrote:

>   http://patches.ubuntu.com/patches/ntp.no-root.diff

hey cool -- i was about to submit a bug-report suggesting that debian 
enable this support.

i found one problem with your patch -- it drops cap_sys_chroot before the 
chroot call.  the following one-liner change applied on top of your patch 
handles that case.

-dean

--- ntp-4.2.0a+stable/ntpd/ntpd.c       2005-02-10 00:26:58.000000000 -0800
+++ ntp-4.2.0a+stable.dg1/ntpd/ntpd.c   2005-02-10 00:22:48.000000000 -0800
@@ -848,7 +848,7 @@
                  *  drop privileges in this case.
                  */
                 cap_t caps;
-                if( ! ( caps = cap_from_text( 
"cap_sys_time,cap_setuid,cap_setgid=pe" ) ) ) {
+                if( ! ( caps = cap_from_text( 
"cap_sys_time,cap_setuid,cap_setgid,cap_sys_chroot=pe" ) ) ) {
                         msyslog( LOG_ERR, "cap_from_text() failed: %m" );
                         exit(-1);
                 }


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to