Bug#524575: -k is not a modprobe switch

2009-04-18 Thread Quentin Godfroy
Package: mdadm
Version: 2.6.8-12-gb47dff6-2
Severity: critical

The modprobe md line in /etc/init.d/mdadm-raid
uses the modprobe switch -k which is not recognised by /sbin/modprobe (as of
module-init-tools 3.7-pre9-1).

$ cat /etc/init.d/mdadm-raid
...
|  if [ ! -f /proc/mdstat ]  [ -x $(command -v modprobe) ] ; then
|modprobe -kq md 2/dev/null || :
|  fi
|  if [ ! -f /proc/mdstat ]; then
|log_problem failed to load MD subsystem
|exit 0
...
$ /sbin/modprobe -kq md
/sbin/modprobe: invalid option -- 'k'
Usage: /sbin/modprobe [-v] [-V] [-C config-file] [-d dirname ] [-n] [-i]
[-q] [-b] [-o modname] [ --dump-modversions ] modname [parameters...]
/sbin/modprobe -r [-n] [-i] [-v] modulename ...
/sbin/modprobe -l -t dirname [ -a modulename ...]
$

No raid array is assembled on reboot, and the machine is lost.



-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#523124: CUPS has stale printers appearing if browsing whith short names is enabled and another host suddently changes its ip

2009-04-08 Thread Quentin Godfroy
Package: cups
Version: 1.3.8-1lenny4.1

Context : local cupsd accepts browsing messages, with BrowseShortNames
enabled.

if a remote cupsd server which publishes printers changes suddently its IP a
new printer with a long name (but the same name before '@') is created
locally and old one still exists (this is not the bug).

The problem is that the short name becomes quickly stale in the sense that
it becomes bound to the device URI file:/dev/null, never expires and
survives restarts of cupsd service.

Moreover cupsd still considers these stale printers as valid printers and it
is possible to have jobs waiting to be printed by these non-existant
printers.

The only way to get rid of these entries is to stop cupsd, remove stale
entries from /var/cache/cups/remote.cache and restart cupsd.

The solution would be to allow these stale entries to expire the same way as
normal printers, as any device listed in remote.cache shoud do.

For example, I have on my system two of these stale printers, as lpstat -v
shows :

$ lpstat -v
device for HP_Deskjet_F300_series: /dev/null
device for hp_deskjet_f300_ser...@macbook250go-2.local: 
ipp://MacBook250Go-2.local:631/printers/HP_Deskjet_F300_series
device for SONA: ipp://sona/ipp/
device for wifi_HP_Deskjet_F300_series: /dev/null
device for wifi_hp_deskjet_f300_ser...@macbook250go-2.local: 
ipp://MacBook250Go-2.local:631/printers/wifi_HP_Deskjet_F300_series

Clearly the address of MacBook250Go-2.local changed at some point of the day
(maybe hours before), but the stale printers did not disappear.

The corresponding /var/cache/cups/remote.cache :
|# Remote cache file for CUPS v1.3.8
|# Written by cupsd on 2009-04-08 18:56
|Printer HP_Deskjet_F300_series
|Type 16879620
|BrowseTime 1239199085
|Info HP Deskjet F300 series
|Location Ordinateur de Roberto Mantaci (2)
|DeviceURI file:/dev/null
|State Idle
|Accepting Yes
|JobSheets none none
|/Printer
|Printer hp_deskjet_f300_ser...@macbook250go-2.local
|Type 16814086
|BrowseTime 1239210058
|Info HP Deskjet F300 series
|MakeModel HP DeskJet F300 Series All in One on MacBook250Go-2.local
|Location Ordinateur de Roberto Mantaci (2)
|DeviceURI ipp://MacBook250Go-2.local:631/printers/HP_Deskjet_F300_series
|State Idle
|Accepting Yes
|JobSheets none none
|Option job-sheets none,none
|Option lease-duration 300
|/Printer
|Printer wifi_HP_Deskjet_F300_series
|Type 16887820
|BrowseTime 1239199085
|Info wifi HP Deskjet F300 series
|Location Base Station 0968e5
|DeviceURI file:/dev/null
|State Idle
|Accepting Yes
|JobSheets none none
|/Printer
|Printer wifi_hp_deskjet_f300_ser...@macbook250go-2.local
|Type 16822286
|BrowseTime 1239210060
|Info wifi HP Deskjet F300 series
|MakeModel HP Deskjet F2100 series on MacBook250Go-2.local
|Location Base Station 0968e5
|DeviceURI
|ipp://MacBook250Go-2.local:631/printers/wifi_HP_Deskjet_F300_series
|State Idle
|Accepting Yes
|JobSheets none none
|Option job-sheets none,none
|Option lease-duration 300
|/Printer

Note that stale entries do not have a Option lease-duration 300, so they
will not expire on the next cupsd start.

My cupsd.conf:
|#
|#
|#   Sample configuration file for the Common UNIX Printing System (CUPS)
|#   scheduler.  See man cupsd.conf for a complete description of this
|#   file.
|#
|
|# Log general information in error_log - change info to debug for
|# troubleshooting...
|LogLevel warning
|
|# Administrator user group...
|SystemGroup lpadmin
|
|
|# Only listen for connections from the local machine.
|Listen localhost:631
|Listen /var/run/cups/cups.sock
|
|# Show shared printers on the local network.
|Browsing On
|BrowseOrder allow,deny
|BrowseAllow all
|
|# Default authentication type, when authentication is required...
|DefaultAuthType Basic
|
|# Restrict access to the server...
|Location /
|  Order allow,deny
|/Location
|
|# Restrict access to the admin pages...
|Location /admin
|  Order allow,deny
|/Location
|
|# Restrict access to configuration files...
|Location /admin/conf
|  AuthType Default
|  Require user @SYSTEM
|  Order allow,deny
|/Location
|
|# Set the default printer/job policies...
|Policy default
|  # Job-related operations must be done by the owner or an administrator...
|  Limit Send-Document Send-URI Hold-Job Release-Job Restart-Job Purge-Jobs
|Set-Job-Attributes Create-Job-Subscription Renew-Subscription
|Cancel-Subscription Get-Notifications Reprocess-Job Cancel-Current-Job
|Suspend-Current-Job Resume-Job CUPS-Move-Job
|Require user @OWNER @SYSTEM
|Order deny,allow
|  /Limit
|
|  # All administration operations require an administrator to
|  # authenticate...
|  Limit CUPS-Add-Modify-Printer CUPS-Delete-Printer CUPS-Add-Modify-Class
|CUPS-Delete-Class CUPS-Set-Default
|AuthType Default
|Require user @SYSTEM
|Order deny,allow
|  /Limit
|
|  # All printer operations require a printer operator to authenticate...
|  Limit Pause-Printer Resume-Printer Enable-Printer Disable-Printer
|Pause-Printer-After-Current-Job Hold-New-Jobs 

Bug#460530: peekfd: segfaults if an fd argument is supplied

2008-06-08 Thread Quentin Godfroy
It would be a *very good* idea to commit the patch.



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



Bug#469635: pam_unix fails to update password on NIS

2008-03-06 Thread Quentin Godfroy
Package: libpam-modules
Version: 0.99.7.1-5

The passwd target of the module pam_unix fails to update passwords on NIS,
even when the argument nis is given.

(something like
password   required   pam_unix.so nis nullok obscure min=4 md5
in /etc/pam.d/common-passwd)

The command passwd fails just after the old password is entered :

$ passwd
Changing password for quentin.
(current) UNIX password: 
passwd: Authentication service cannot retrieve authentication info
passwd: password unchanged
$

The problem lies within the function pam_unix_passwd.c:_unix_verify_shadow,
which calls _unix_getpwnam with bad arguments. This call was added with
Debian patch 026_pam_unix_passwd_unknown_user.

I suggest the following patch be applied (it has to be applied on the patched 
tree,
but maybe it was not the good way to do)

It also corrects another call to _unix_getpwnam, where a nis call is tried
even when nis is not given in the command line.

It was tried on NIS with shadow support and also on a machine without nis and
without the nis switch on the module command.

---
Signed-off-by: Quentin Godfroy [EMAIL PROTECTED]
diff -ruNp pam-0.99.7.1/Linux-PAM/modules/pam_unix/pam_unix_passwd.c 
pam-0.99.7.1-patch/Linux-PAM/modules/pam_unix/pam_unix_passwd.c
--- pam-0.99.7.1/Linux-PAM/modules/pam_unix/pam_unix_passwd.c   2008-03-05 
20:30:37.0 +0100
+++ pam-0.99.7.1-patch/Linux-PAM/modules/pam_unix/pam_unix_passwd.c 
2008-03-05 21:30:56.0 +0100
@@ -879,7 +879,7 @@ static int _unix_verify_shadow(pam_handl
int retval = PAM_SUCCESS;
 
/* UNIX passwords area */
-   _unix_getpwnam(pamh, user, 1, 0, pwd); /* Get password *file* entry... 
*/
+   _unix_getpwnam(pamh, user, 1, on(UNIX_NIS, ctrl), pwd);/* Get 
password entry... */
if (pwd == NULL)
return PAM_AUTHINFO_UNAVAIL;/* We don't need to do the 
rest... */
 
@@ -1073,7 +1073,7 @@ PAM_EXTERN int pam_sm_chauthtok(pam_hand
return PAM_USER_UNKNOWN;
} else {
struct passwd *pwd;
-   _unix_getpwnam(pamh, user, 1, 1, pwd);
+   _unix_getpwnam(pamh, user, 1, on(UNIX_NIS, ctrl), pwd);
if (pwd == NULL) {
pam_syslog(pamh, LOG_DEBUG,
user \%s\ has corrupted passwd entry,
@@ -1155,7 +1151,7 @@ PAM_EXTERN int pam_sm_chauthtok(pam_hand
pam_syslog(pamh, LOG_CRIT,
 failed to set PAM_OLDAUTHTOK);
}
-   retval = _unix_verify_shadow(pamh,user, ctrl);
+   retval = _unix_verify_shadow(pamh, user, ctrl);
if (retval == PAM_AUTHTOK_ERR) {
if (off(UNIX__IAMROOT, ctrl))
_make_remark(pamh, ctrl, PAM_ERROR_MSG,



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



Bug#424920: pdftk update_info corrupts the CreationDate and ModDate fields

2008-01-20 Thread Quentin Godfroy
The reason is that all the strings in the info directory are written in
UTF-16, which is OK for all the keys but for ModDate and CreationDate,
which need to be in ASCII.

Until the sixth edition of the PDF reference book, it was unclear if this
was accepted. (The text says that CreationDate and ModDate are of the date
type, which in turn is a string which is different from a text string)
(sections 3.8.0-2 and 8.2 of the second edition). The sixth edition mades
clear however that dates are ASCII strings (table 10.2 and section 3.8.0-3).

I suggest something like this patch to be applied. (note that I'm not
familiar at all with C++ so I kind of guessed what had to be changed)

Regards,
Quentin Godfroy

---
Signed-off by: Quentin Godfroy [EMAIL PROTECTED]

diff -ruNp pdftk-1.41/pdftk/report.cc pdftk-1.41-patch/pdftk/report.cc
--- pdftk-1.41/pdftk/report.cc  2006-09-06 01:49:32.0 +0200
+++ pdftk-1.41-patch/pdftk/report.cc2008-01-21 02:19:44.0 +0100
@@ -1228,7 +1228,7 @@ UpdateInfo( itext::PdfReader* reader_p,

string_to_jcharstring( jvs, jvs_size, jvs_len, it-second );
 
info_p-put( 
new itext::PdfName( JvNewStringLatin1(it-first.c_str()) ),
-   
 new itext::PdfString( JvNewString(jvs, 
jvs_len), itext::PdfObject::TEXT_UNICODE ) );
+   
 new itext::PdfString( JvNewString(jvs, 
jvs_len), (strcmp(it-first.c_str(), ModDate)  strcmp(it-first.c_str(), 
CreationDate)) ? itext::PdfObject::TEXT_UNICODE : 
itext::PdfObject::TEXT_PDFDOCENCODING) );
}
}
}



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



Bug#451721: module-assistant -u path does not detect ACL

2007-11-17 Thread Quentin Godfroy
Package: module-assistant
Version: 0.10.11

module-assistant -u path with path writeable thanks to ACLs does not
correctly detect the write permissions. It then fails with 

path is not writeable!

I suggest the following patch be applied
---
Signed-off-by: Quentin Godfroy [EMAIL PROTECTED]
--- module-assistant.back   2006-11-15 16:32:21.0 +0100
+++ module-assistant2007-11-18 00:21:01.0 +0100
@@ -45,6 +45,7 @@ my $ret=0;
 use Getopt::Long qw(:config no_ignore_case bundling pass_through);
 use File::Basename;
 use Cwd;
+use filetest 'access';
 
 $res = (defined($ENV{MA_DIR})) ? $ENV{MA_DIR} : /usr/share/modass;
 $var= (defined($ENV{MA_VARDIR})) ? $ENV{MA_VARDIR} : /var/cache/modass;



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



Bug#451324: Sudo closes every possible fd from 3 to the upper limit

2007-11-14 Thread Quentin Godfroy
Package: sudo
Version: 1.6.9p6-1

On a setup where the limit for open files is set to 1048576, sudo takes half
a second to do the simplest task. The reason behind this is that at startup
it closes all fds after the one associated with stderr, which makes 1048573
system calls.

There is code in sudo which looks for open fds in /dev/fd/, but the
configure fails to detect that the libc has dirfd, and so sudo uses the dumb
algorithm.

Configure tries to compile this code,

#include sys/types.h
#include dirent.h
int
main ()
{
DIR d; (void)dirfd(d);
  ;
  return 0;
}

which fails because the glibc (at least in 2.6.1-1+b1) includes do not
expose the structure of a DIR * (and there seems no reason to do so)

I suggest the following patch be applied. (autoconf has to be rerun after
this)
---
Signed-off-by: Quentin Godfroy [EMAIL PROTECTED]
--- configure.in.bak2007-11-15 00:20:03.0 +0100
+++ configure.in2007-11-15 00:20:54.0 +0100
@@ -1727,7 +1727,7 @@ dnl
 dnl Check for the dirfd function/macro.  If not found, look for dd_fd in DIR.
 dnl
 AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include sys/types.h
-#include $ac_header_dirent]], [[DIR d; (void)dirfd(d);]])], 
[AC_DEFINE(HAVE_DIRFD)], [AC_TRY_LINK([#include sys/types.h
+#include $ac_header_dirent]], [[DIR *d; (void)dirfd(d);]])], 
[AC_DEFINE(HAVE_DIRFD)], [AC_TRY_LINK([#include sys/types.h
 #include $ac_header_dirent], [DIR d; memset(d, 0, sizeof(d)); 
return(d.dd_fd);], [AC_DEFINE(HAVE_DD_FD)])])
 dnl
 dnl If NEED_SNPRINTF is set, add snprintf.c to LIBOBJS



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



Bug#449137: Initscript fails to mount /var/lib/nfs/rpc_pipefs

2007-11-03 Thread Quentin Godfroy
Package: nfs-common
Version: 1:1.1.1-6

Hi,

on a system where the kernel modules nfs and nfs4 are not compiled in (e.g.
on a box acting only as a server), the initscript fails to mount 
/var/lib/nfs/rpc_pipefs which prevents idmapd to start.

Amusingly, after the initscript nfs-kernel-server was launched, manually
launching '/etc/init.d/nfs-common start' starts rpc.idmapd, which made the
problem difficult to debug.

I suggest this patch could solve the problem.

---
Signed-off by: Quentin Godfroy [EMAIL PROTECTED]
--- /etc/init.d/nfs-common-bak  2007-11-03 12:25:43.0 +0100
+++ /etc/init.d/nfs-common  2007-11-03 13:33:57.0 +0100
@@ -138,8 +138,7 @@ case $1 in
 
if [ $NEED_IDMAPD = yes ] || [ $NEED_GSSD = yes ]
then
-   do_modprobe nfs
-   do_modprobe nfs4
+   do_modprobe sunrpc
if do_mount rpc_pipefs $PIPEFS_MOUNTPOINT
then
if [ $NEED_IDMAPD = yes ]



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



Bug#448656: nfs-common : typo in initscript

2007-10-30 Thread Quentin Godfroy
Package: nfs-common
Version: 1:1.1.1-4

Hi,

in line 201 of /etc/init.d/nfs-common, there is a

if [$NEED_STATD = yes ]

instead of

if [ $NEED_STATD = yes ]

which prevents statd daemon to be correctly stopped



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



Bug#421341: Something wrong with gcjh/classpath/something

2007-10-19 Thread Quentin Godfroy
On Fri, 14 Sep 2007 18:41:53 +0200, Michael Bienia [EMAIL PROTECTED] wrote:

 pdftk in Ubuntu gutsy has the same problem. If my analysis is correct
 than that's because it uses some local copies of gcc-4.1 files.
 If I modify the build to not use them (a comment in pdftk/Makefile.Base
 states that they were introduced as some old version of libgcj doesn't
 have MD5) pdftk works again.

 I've attached the changes I did to fix it in Ubuntu.

With this patch and the previous one, I am able to compile and run pdftk
with dpkg-buildpackage.
Thanks.

Are you waiting for an upstream update to see if it is useful to commit
these two patches in the package?

Regards,
Quentin Godfroy



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



Bug#446707: opiekey refuses seed=0

2007-10-14 Thread Quentin Godfroy
Package: opie-client
Version: 2.32-10.2

opiekey refuses to compute responses with seed=0, which seems to be allowed by
RFC 2289 (e.g. tests vectors from pg.17), and is accepted by opiepasswd for
example.

Transcript follows:

% opiekey 0 alpha1
Using the MD5 algorithm to compute response.
Sequence number 0 is not positive.
%

I suggest the following patch to be applied.

Signed-off-by: Quentin Godfroy [EMAIL PROTECTED]
---
diff -ruNp opie-2.32-orig/opiekey.c opie-2.32/opiekey.c
--- opie-2.32-orig/opiekey.c1998-01-02 00:53:28.0 +0100
+++ opie-2.32/opiekey.c 2007-10-15 02:39:03.0 +0200
@@ -217,7 +217,7 @@ int main FUNCTION((argc, argv), int argc
 
   /* get sequence number, which is next-to-last parameter */
   keynum = atoi(argv[optind]);
-  if (keynum  1) {
+  if (keynum  0) {
 fprintf(stderr, Sequence number %s is not positive.\n, argv[optind]);
 exit(1);
   }



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



Bug#444155: Regexp pb in /etc/init.d/nfs-common

2007-09-26 Thread Quentin Godfroy
Package: nfs-common
Version: 1:1.1.1~git-20
Severity: normal

In /etc/init.d/nfs-common, the test in line 66 may not report a working
/etc/exports file, thus disabling the spawning of an idmapd in case the
/etc/default/nfs-common variable NEED_IDMAPD is not set. It could cause
problems for NFSv4 mounts.

More precisely, to be reported, the current test requires that there are
lines which begin with a space, which lets think the mistake is a typo.

I suggest applying the following patch :

--- /etc/init.d/nfs-common.saved2007-09-26 14:41:32.0 +0200
+++ /etc/init.d/nfs-common  2007-09-26 15:10:11.0 +0200
@@ -63,7 +63,7 @@ fi
 # condition in nfs-kernel-server's init script does, which has a value in
 # itself.
 #
-if [ -f /etc/exports ]  grep -q '^ .*/' /etc/exports; then
+if [ -f /etc/exports ]  grep -q '^[[:space:]]*[^#]*/' /etc/exports; then
 AUTO_NEED_IDMAPD=yes
 fi




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



Bug#421978: ia32_aout fails to load automatically on x86_64-linux

2007-05-02 Thread Quentin Godfroy
Package: module-init-tools
Version: 3.3-pre4-2
Subject: ia32_aout fails to load automatically on x86_64-linux

On x86_64 when trying to execute a a.out QMAGIC executable, with the
module ia32_aout unloaded, the kernel tries to load binfmt-0064, but
the file /etc/modprobe/arch-aliases (strangely a symlink to
/etc/modprobe.d/arch/i386) defines binfmt-0064 as an alias to binfmt_aout,
which is wrong because the module is called ia32_aout. I suggest to add
the file /etc/modprobe.d/arch/x86_64 attached to this mail and to make
the symlink /etc/modprobe/arch-aliases pointing to it.
alias parport_lowlevel parport_pc

alias binfmt-0064 ia32_aout
alias binfmt-332 iBCS