home bbs files messages ]

Forums before death by AOL, social media and spammers... "We can't have nice things"

   linux.debian.bugs.dist      Ohh some weird Debian bug report thing      28,835 messages   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]

   Message 28,353 of 28,835   
   Vincent Blut to Debian Bug Tracking System   
   trixie-pu: package chrony/4.6.1-3+deb13u   
   20 Feb 26 22:06:49   
   
   XPost: linux.debian.devel.release   
   From: vincent.debian@free.fr   
      
   --Eel79KRUwFfqeGuO   
   Content-Type: text/plain; charset=utf-8   
   Content-Disposition: inline   
   Content-Transfer-Encoding: quoted-printable   
      
   Package: release.debian.org   
   Severity: normal   
   Tags: trixie   
   X-Debbugs-Cc: chrony@packages.debian.org   
   Control: affects -1 + src:chrony   
   User: release.debian.org@packages.debian.org   
   Usertags: pu   
      
   Hi,   
      
   [ Reason ]   
   A security fix introduced in Linux 6.15¹, and backported to Linux stable   
   series down to version 5.10, prevents chronyd from starting if   
   it is set up to use a PHC refclock configured with the 'extpps' option.   
      
   [ Impact ]   
   chronyd would fail to start when configured as aforementioned on a system   
   featuring a kernel containing that security fix.   
      
   More precisely, chronyd would output: "Fatal error : Could not enable external   
   PHC timestamping"   
      
   [ Tests ]   
   After some required adjustments to 'upstream-simulation-test-suite'   
   autopkgest, all the tests shipped by chrony pass.   
      
   The proposed fix has also been successfully tested by the person who reported   
   the bug. No regression has been observed.   
      
   [ Risks ]   
   As mentioned above, the proposed update is well tested so I would say   
   that the risk of regression should be quite low.   
      
   [ Checklist ]   
     [x] *all* changes are documented in the d/changelog   
     [x] I reviewed all changes and I approve them   
     [x] attach debdiff against the package in (old)stable   
     [x] the issue is verified as fixed in unstable   
      
   [ Changes ]   
   - The refclock_phc_open-device-for-writing-with-extpps-option.patch file   
     is a backport of upstream patch (already available in chrony 4.8) to   
     open the PHC reference clock with the O_RDWR flag when enabling the   
     extpps option as recently required by the kernel.   
      
   - The second change concerns the 'upstream-simulation-test-suite'   
     autopkgtest that fails notably due to the patched open() call.   
      
   [ Other info ]   
   I will be filing an issue for bookworm to fix the same problem.   
      
   Cheers,   
   Vincent   
      
   ¹ https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.   
   it/commit/?id=97529630d85f910f4e6dfc615f1d111ada9448e3   
      
   --Eel79KRUwFfqeGuO   
   Content-Type: text/plain; charset=utf-8   
   Content-Disposition: attachment; filename="chrony_4.6.1-3+deb13u1.debdiff"   
   Content-Transfer-Encoding: quoted-printable   
      
   diff -Nru chrony-4.6.1/debian/changelog chrony-4.6.1/debian/changelog   
   --- chrony-4.6.1/debian/changelog	2025-06-03 17:16:37.000000000 +0200   
   +++ chrony-4.6.1/debian/changelog	2026-02-16 17:34:12.000000000 +0100   
   @@ -1,3 +1,14 @@   
   +chrony (4.6.1-3+deb13u1) trixie; urgency=medium   
   +   
   +  * debian/patches/:   
   +    - Add refclock_phc_open-device-for-writing-with-extpps-option.patch.   
   +    Thanks to Jan Lübbe for the report. (Closes: #1127659)   
   +   
   +  * debian/test/upstream-simulation-test-suite:   
   +    - Prevent simulation test failures.   
   +   
   + -- Vincent Blut   Mon, 16 Feb 2026 17:34:12 +0100   
   +   
    chrony (4.6.1-3) unstable; urgency=medium   
       
      * debian/patches/:   
   diff -Nru chrony-4.6.1/debian/patches/refclock_phc_open-device-f   
   r-writing-with-extpps-option.patch chrony-4.6.1/debian/patches/r   
   fclock_phc_open-device-for-writing-with-extpps-option.patch   
   --- chrony-4.6.1/debian/patches/refclock_phc_open-device-for-wri   
   ing-with-extpps-option.patch	1970-01-01 01:00:00.000000000 +0100   
   +++ chrony-4.6.1/debian/patches/refclock_phc_open-device-for-wri   
   ing-with-extpps-option.patch	2026-02-16 17:34:12.000000000 +0100   
   @@ -0,0 +1,104 @@   
   +Description: Open PHC device for writing with extpps option   
   + In version 6.15 the Linux kernel started checking write access on the   
   + PHC file descriptor in the PTP_PIN_SETFUNC and PTP_EXTTS_REQUEST ioctls.   
   + chronyd opened the PHC device as readonly, which caused the PHC refclock   
   + driver configured with the extpps option to fail with the   
   + "Could not enable external PHC timestamping" error message.   
   +   
   + To ensure compatibility with new kernel versions, add flags to the   
   + SYS_Linux_OpenPHC() function and open the device with the O_RDWR flag   
   + when the extpps option is enabled.   
   +Origin: backport, https://gitlab.com/chrony/chrony/-/commit/f78   
   4681eff71d941fab3be5ee406d920a155a20   
   +Bug-Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1127659   
   +Last-Update: 2026-02-12   
   +---   
   +Index: chrony/ntp_io_linux.c   
   +===================================================================   
   +--- chrony.orig/ntp_io_linux.c   
   ++++ chrony/ntp_io_linux.c   
   +@@ -220,7 +220,7 @@ add_interface(CNF_HwTsInterface *conf_if   
   +    
   +   SCK_CloseSocket(sock_fd);   
   +    
   +-  phc_fd = SYS_Linux_OpenPHC(NULL, ts_info.phc_index);   
   ++  phc_fd = SYS_Linux_OpenPHC(NULL, ts_info.phc_index, O_RDONLY);   
   +   if (phc_fd < 0)   
   +     return 0;   
   +    
   +Index: chrony/refclock_phc.c   
   +===================================================================   
   +--- chrony.orig/refclock_phc.c   
   ++++ chrony/refclock_phc.c   
   +@@ -66,7 +66,7 @@ static int phc_initialise(RCL_Instance i   
   + {   
   +   const char *options[] = {"nocrossts", "extpps", "pin", "channel", "clear",   
   NULL};   
   +   struct phc_instance *phc;   
   +-  int phc_fd, rising_edge;   
   ++  int rising_edge;   
   +   struct stat st;   
   +   char *path, *s;   
   +    
   +@@ -74,19 +74,20 @@ static int phc_initialise(RCL_Instance i   
   +    
   +   path = RCL_GetDriverParameter(instance);   
   +     
   +-  phc_fd = SYS_Linux_OpenPHC(path, 0);   
   +-  if (phc_fd < 0)   
   +-    LOG_FATAL("Could not open PHC");   
   +-   
   +   phc = MallocNew(struct phc_instance);   
   +-  phc->fd = phc_fd;   
   +-  if (fstat(phc_fd, &st) < 0 || !S_ISCHR(st.st_mode))   
   +-    LOG_FATAL("Could not get PHC index");   
   +-  phc->dev_index = minor(st.st_rdev);   
   +   phc->mode = 0;   
   +   phc->nocrossts = RCL_GetDriverOption(instance, "nocrossts") ? 1 : 0;   
   +   phc->extpps = RCL_GetDriverOption(instance, "extpps") ? 1 : 0;   
   +   UTI_ZeroTimespec(&phc->last_extts);   
   ++   
   ++  phc->fd = SYS_Linux_OpenPHC(path, 0, phc->extpps ? O_RDWR : O_RDONLY);   
   ++  if (phc->fd < 0)   
   ++    LOG_FATAL("Could not open PHC");   
      
   [continued in next message]   
      
   --- SoupGate-Win32 v1.05   
    * Origin: you cannot sedate... all the things you hate (1:229/2)   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]


(c) 1994,  bbs@darkrealms.ca