Bug#680939: Bug#681350: libconvert-asn1-perl: use strict breaks smbldap-tools

2012-07-19 Thread Saulo Soares de Toledo

  OK, I'll update the package, but maybe we should wait till the end of
 the week
  and ask for a new release of smbldap-tools, as the one in Debian is
 already
  outdated.


I think if we can test the package with an empty installation can bring us
a faster new smbldap-tools release. We should test if with an empty
installation we have some other bugs derived from use strict at perl.
After some tests, I think we can ask smbldap-tools developer's team to a
new release.


  And, anyway, I'm not using smbldap-tools anymore, if anyone on the Cc:
 list
  wants to take over mainteinance, be my guest, please.

 I'm sorry I'm not using smbldap-tools too, tt only appeared on my
 'radar' some time ago to remove the Digest::SHA1 dependency which was
 one goal of the Debian Perl Group, and now due to the bugreport from
 Saulo on libconvert-asn1-perl.


I'd like to help here, but I'm an occasional user of the package, and my
servers are always to small networks, I'm not the right mantainer to this
package...


  BTW, I've already have the latest upstream version packaged, but I didn't
  uploaded it because I wanted to see how many debian bugs were closed by
 it and
  didn't had the time to look into it and test (I planned to use a LXC
 container
  with a clean installation of a system with OpenLDAP and SAMBA, but I
 haven't
  been able to work on it in the last weeks).

 This is great, as more (important) bugs fixed with a new release the
 better. Again, sorry cannot help here good, but maybe Saulo can
 provide some feedback?


Really sorry, I would like to help here, but I can't do it this days.
Anyway, if I get some news with this question, I will update this report.

I think we should wait some more days. We need make sure we have no another
 critical bug. smbldap-tools team updated only 2 of the scripts...

Thanks

Saulo


Bug#680939: Bug#681350: libconvert-asn1-perl: use strict breaks smbldap-tools

2012-07-17 Thread Sergio Talens-Oliag
El Mon, Jul 16, 2012 at 08:53:37PM +0200, Salvatore Bonaccorso va escriure:
 Hi Saulo
 
 (dropping the merged bugreport)
 
 On Mon, Jul 16, 2012 at 12:42:00PM -0300, Saulo Soares de Toledo wrote:
  News about the bug.
  I received a response from SATOH Fumiyasu, smbldap-tools developer, about
  the problem. It's fixed to smbldap-userlist and smbldap-grouplist at SVN
  (revision 135):
  
  http://svn.gna.org/viewcvs/smbldap-tools?view=revisionrevision=135
  
  It's needed check if there are other scripts with failures yet to close the
  bug.
  
  Thanks all!
 
 Cool, thanks for keeping up on that! Indeed the commited solution is
 much cleaner, safer and better als the eval workaround.
 
 Sergio, Release-Team should be asked, but it seems a little enough
 change that could have a possiblity to get a freeze-exception for this
 fix.

OK, I'll update the package, but maybe we should wait till the end of the week
and ask for a new release of smbldap-tools, as the one in Debian is already
outdated.

And, anyway, I'm not using smbldap-tools anymore, if anyone on the Cc: list
wants to take over mainteinance, be my guest, please.

BTW, I've already have the latest upstream version packaged, but I didn't
uploaded it because I wanted to see how many debian bugs were closed by it and
didn't had the time to look into it and test (I planned to use a LXC container
with a clean installation of a system with OpenLDAP and SAMBA, but I haven't
been able to work on it in the last weeks).

Greetings,

  Sergio.

-- 
Sergio Talens-Oliag s...@debian.org   http://people.debian.org/~sto/
Key fingerprint = 29DF 544F  1BD9 548C  8F15 86EF  6770 052B  B8C1 FA69


signature.asc
Description: Digital signature


Bug#680939: Bug#681350: libconvert-asn1-perl: use strict breaks smbldap-tools

2012-07-17 Thread Salvatore Bonaccorso
Hi Sergio

First of all thanks for the quick reply!

On Tue, Jul 17, 2012 at 09:56:03AM +0200, Sergio Talens-Oliag wrote:
 El Mon, Jul 16, 2012 at 08:53:37PM +0200, Salvatore Bonaccorso va escriure:
  Hi Saulo
  
  (dropping the merged bugreport)
  
  On Mon, Jul 16, 2012 at 12:42:00PM -0300, Saulo Soares de Toledo wrote:
   News about the bug.
   I received a response from SATOH Fumiyasu, smbldap-tools developer, about
   the problem. It's fixed to smbldap-userlist and smbldap-grouplist at SVN
   (revision 135):
   
   http://svn.gna.org/viewcvs/smbldap-tools?view=revisionrevision=135
   
   It's needed check if there are other scripts with failures yet to close 
   the
   bug.
   
   Thanks all!
  
  Cool, thanks for keeping up on that! Indeed the commited solution is
  much cleaner, safer and better als the eval workaround.
  
  Sergio, Release-Team should be asked, but it seems a little enough
  change that could have a possiblity to get a freeze-exception for this
  fix.
 
 OK, I'll update the package, but maybe we should wait till the end of the week
 and ask for a new release of smbldap-tools, as the one in Debian is already
 outdated.

Please keep in mind that we are in the freeze for wheezy, so we should
have an eye on rules from release-team[1]. So an upload should
preferably only fix some of the 'important' marked bugs in BTS or
changes which absolutely need to go to wheezy.

 [1]: http://release.debian.org/wheezy/freeze_policy.html

 And, anyway, I'm not using smbldap-tools anymore, if anyone on the Cc: list
 wants to take over mainteinance, be my guest, please.

I'm sorry I'm not using smbldap-tools too, tt only appeared on my
'radar' some time ago to remove the Digest::SHA1 dependency which was
one goal of the Debian Perl Group, and now due to the bugreport from
Saulo on libconvert-asn1-perl.

 BTW, I've already have the latest upstream version packaged, but I didn't
 uploaded it because I wanted to see how many debian bugs were closed by it and
 didn't had the time to look into it and test (I planned to use a LXC container
 with a clean installation of a system with OpenLDAP and SAMBA, but I haven't
 been able to work on it in the last weeks).

This is great, as more (important) bugs fixed with a new release the
better. Again, sorry cannot help here good, but maybe Saulo can
provide some feedback?

Regards,
Salvatore


signature.asc
Description: Digital signature


Bug#681350: libconvert-asn1-perl: use strict breaks smbldap-tools

2012-07-16 Thread Saulo Soares de Toledo
News about the bug.
I received a response from SATOH Fumiyasu, smbldap-tools developer, about
the problem. It's fixed to smbldap-userlist and smbldap-grouplist at SVN
(revision 135):

http://svn.gna.org/viewcvs/smbldap-tools?view=revisionrevision=135

It's needed check if there are other scripts with failures yet to close the
bug.

Thanks all!

Saulo


2012/7/13 Saulo Soares de Toledo saulotol...@gmail.com

 No response from smbldap-tools developers at
 http://gna.org/project/memberlist.php?group=smbldap-tools yet.

 Somebody can help with them?



 2012/7/13 Salvatore Bonaccorso car...@debian.org

 Hi Saulo

 btw, what smbldap-tools can do, is to workaround this is to use 'eval'.

 so in a example something like:

 cut-cut-cut-cut-cut-cut-
 #!/usr/bin/perl

 use strict 'refs';

 my $attrs = [ 'foo', 'bar', ];
 $attrs = eval $attrs;

 push @{$attrs}, 'foobar';

 use Data::Dumper 'Dumper';
 warn Dumper [$attrs];
 cut-cut-cut-cut-cut-cut-

 But again, this is more a hack.

 Regards,
 Salvatore

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

 iQIcBAEBCAAGBQJQADyBAAoJEHidbwV/2GP++4MQAIKa6PQ+e7dR/bmJKo7UwvXg
 qvnHzCxYUd14yLPwyuD8lqQfLCn+oOrhaIkMGln0AfvoF7eJp1VgMIMET3CkWElk
 2nGG//fcCxibtVHQD4sBtSbt3YokVeN0CO0hnizGwDCy7FJo+RUNMBT7pRn9KdMb
 vlxu5tZ5ySlTPfiMNqhFAyyDFtbjx/5G1xj/xva1ePNjqAdn25eIu7+1pIlQi0Bm
 qT7h6qmcOuSHd88y0zxw4e1zZDxE/tPL6XuVLmBzt1ToJdqJBFY6cZDbIBENX50+
 RdhFJPEN7iZywIZXGVPyg7q60Mv8IOW6adoSfM29TGbpaD1/dOwSvHQ0L5CMLy1b
 srDDfgB6xbSL1InmHt4x/i8Es7tpK4GmXRtE2s+/jS6By7VBOEONXvSCFlsJweZ/
 LWQ08hyUxpvEV4gCHvq5CE1JF3ueFb5LpvqCgxWm0qbgtCQS90ORwT59UFYcN1oc
 hTCkHzpK1TVCozjLCDH69USkYQV4c1cdVOlS9jvD/E3UsEj5PeZH9hKkeS091wJ1
 WL9l1ofJv47BpwHnVDL8rzTUx3s+eKxU+f8ulaE4lns8vZPKRip2Zd33lTVo9XZ7
 48N/ep6luNxrVdMKC4zLi/qynDMe3l9cMwI1flqAjz7fe8/UCgZ6KBu0JLNVKOn9
 jzNXjtURlyaAPCElp6Ve
 =AXrC
 -END PGP SIGNATURE-





Bug#680939: Bug#681350: libconvert-asn1-perl: use strict breaks smbldap-tools

2012-07-16 Thread Salvatore Bonaccorso
Hi Saulo

(dropping the merged bugreport)

On Mon, Jul 16, 2012 at 12:42:00PM -0300, Saulo Soares de Toledo wrote:
 News about the bug.
 I received a response from SATOH Fumiyasu, smbldap-tools developer, about
 the problem. It's fixed to smbldap-userlist and smbldap-grouplist at SVN
 (revision 135):
 
 http://svn.gna.org/viewcvs/smbldap-tools?view=revisionrevision=135
 
 It's needed check if there are other scripts with failures yet to close the
 bug.
 
 Thanks all!

Cool, thanks for keeping up on that! Indeed the commited solution is
much cleaner, safer and better als the eval workaround.

Sergio, Release-Team should be asked, but it seems a little enough
change that could have a possiblity to get a freeze-exception for this
fix.

Regards,
Salvatore


signature.asc
Description: Digital signature


Bug#680939: Bug#681350: libconvert-asn1-perl: use strict breaks smbldap-tools

2012-07-13 Thread Salvatore Bonaccorso
Hi Saulo

btw, what smbldap-tools can do, is to workaround this is to use 'eval'.

so in a example something like:

cut-cut-cut-cut-cut-cut-
#!/usr/bin/perl

use strict 'refs';

my $attrs = [ 'foo', 'bar', ];
$attrs = eval $attrs;

push @{$attrs}, 'foobar';

use Data::Dumper 'Dumper';
warn Dumper [$attrs];
cut-cut-cut-cut-cut-cut-

But again, this is more a hack.

Regards,
Salvatore


signature.asc
Description: Digital signature


Bug#681350: libconvert-asn1-perl: use strict breaks smbldap-tools

2012-07-12 Thread Saulo Soares de Toledo
Package: libconvert-asn1-perl
Version: 0.26-1
Severity: important

Dear Maintainer,

At file /usr/share/perl5/Convert/ASN1/_encode.pm, line 10, there is use
strict;.

With this active, smbldap-tools package, used at Samba + LDAP environments,
stop working. This is really necessary at Debian?

Since smbldap-tools is necessary at Samba servers with LDAP, it's a real
problem.


-- System Information:
Debian Release: wheezy/sid
  APT prefers testing
  APT policy: (500, 'testing')
Architecture: amd64 (x86_64)

Kernel: Linux 3.2.0-2-amd64 (SMP w/4 CPU cores)
Locale: LANG=pt_BR.UTF-8, LC_CTYPE=pt_BR.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages libconvert-asn1-perl depends on:
ii  libmath-bigint-perl 1.997-1
ii  perl5.14.2-12
ii  perl-modules [libmath-bigint-perl]  5.14.2-12

libconvert-asn1-perl recommends no packages.

libconvert-asn1-perl suggests no packages.

-- no debconf information



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



Bug#681350: libconvert-asn1-perl: use strict breaks smbldap-tools

2012-07-12 Thread gregor herrmann
On Thu, 12 Jul 2012 11:40:26 -0300, Saulo Soares de Toledo wrote:

 At file /usr/share/perl5/Convert/ASN1/_encode.pm, line 10, there is use
 strict;.
 
 With this active, smbldap-tools package, used at Samba + LDAP environments,
 stop working. This is really necessary at Debian?

Well, without looking at it, this very much sounds like a bug in
smbldap-tools ...
 

Cheers,
gregor, who hasn't seen any serious perl code without use strict;

-- 
 .''`.  Homepage: http://info.comodo.priv.at/ - OpenPGP key 0xBB3A68018649AA06
 : :' : Debian GNU/Linux user, admin, and developer  -  http://www.debian.org/
 `. `'  Member of VIBE!AT  SPI, fellow of the Free Software Foundation Europe
   `-   


signature.asc
Description: Digital signature


Bug#681350: libconvert-asn1-perl: use strict breaks smbldap-tools

2012-07-12 Thread Saulo Soares de Toledo
Even the upstream version (0.9.8, not in debian) don't works with strict
enabled.

I think consider remove at _encode.pm file is easiest than report the bug
and wait a new upstream version, since the package is really needed at
Samba + LDAP environments.

2012/7/12 gregor herrmann gre...@debian.org

 On Thu, 12 Jul 2012 11:40:26 -0300, Saulo Soares de Toledo wrote:

  At file /usr/share/perl5/Convert/ASN1/_encode.pm, line 10, there is use
  strict;.
 
  With this active, smbldap-tools package, used at Samba + LDAP
 environments,
  stop working. This is really necessary at Debian?

 Well, without looking at it, this very much sounds like a bug in
 smbldap-tools ...


 Cheers,
 gregor, who hasn't seen any serious perl code without use strict;

 --
  .''`.  Homepage: http://info.comodo.priv.at/ - OpenPGP key
 0xBB3A68018649AA06
  : :' : Debian GNU/Linux user, admin, and developer  -
 http://www.debian.org/
  `. `'  Member of VIBE!AT  SPI, fellow of the Free Software Foundation
 Europe
`-



Bug#681350: libconvert-asn1-perl: use strict breaks smbldap-tools

2012-07-12 Thread Salvatore Bonaccorso
Hi

On Thu, Jul 12, 2012 at 03:39:18PM -0300, Saulo Soares de Toledo wrote:
 Even the upstream version (0.9.8, not in debian) don't works with strict
 enabled.
 
 I think consider remove at _encode.pm file is easiest than report the bug
 and wait a new upstream version, since the package is really needed at
 Samba + LDAP environments.

I agree here with gregor. It is mostly the right thing to add a 'use
strict' to every Perl code. At least a good best practice[1]. The
actual commit which added the mentioned 'use strict' was [2], which at
first glace the diff looks fine to me.

Could you give more information on which problems you see with
smbldap-tools? Should the bugreport reassigned to smbldap-tools?

 [1]: http://www.perlmonks.org/?node_id=475285
 [2]: 
https://github.com/gbarr/perl-Convert-ASN1/commit/00206fb7ca2748c09ed61622a16a412daad71505

Regards,
Salvatore


signature.asc
Description: Digital signature


Bug#681350: libconvert-asn1-perl: use strict breaks smbldap-tools

2012-07-12 Thread Saulo Soares de Toledo
2012/7/12 Salvatore Bonaccorso car...@debian.org

 Could you give more information on which problems you see with
 smbldap-tools? Should the bugreport reassigned to smbldap-tools?


I've opened the bug report 680939 680...@bugs.debian.org to smbldap-tools.
Smbldap-tools is a set of perl scripts designed to manage user and
groupaccounts stored in an LDAP directory. (website description)

Some scripts of the package simple do not works with use sctrict enabled.
The Debian version is 0.9.7, but 0.9.8 (latest from developers) do not
works too. The error returned with smbldap-userlist is:

Can't use string (['username','uidNumber','uid']) as an ARRAY ref while
strict refs in use at /usr/share/perl5/Convert/ASN1/_encode.pm line 269.

Smbldap-tools is needed while using Samba + LDAP. I sent an email do
smbldap-tools developers about the problem and will update here when I get
some more information about.


Bug#680939: Bug#681350: libconvert-asn1-perl: use strict breaks smbldap-tools

2012-07-12 Thread Salvatore Bonaccorso
Hi Saulo

I'm Cc'in the bugreport on smbldap-tools, but I think these two should
be merged and only assigned to smbldap-tools.

On Thu, Jul 12, 2012 at 09:51:54PM -0300, Saulo Soares de Toledo wrote:
 2012/7/12 Salvatore Bonaccorso car...@debian.org
 
  Could you give more information on which problems you see with
  smbldap-tools? Should the bugreport reassigned to smbldap-tools?
 
 
 I've opened the bug report 680939 680...@bugs.debian.org to smbldap-tools.
 Smbldap-tools is a set of perl scripts designed to manage user and
 groupaccounts stored in an LDAP directory. (website description)
 
 Some scripts of the package simple do not works with use sctrict enabled.
 The Debian version is 0.9.7, but 0.9.8 (latest from developers) do not
 works too. The error returned with smbldap-userlist is:
 
 Can't use string (['username','uidNumber','uid']) as an ARRAY ref while
 strict refs in use at /usr/share/perl5/Convert/ASN1/_encode.pm line 269.
 
 Smbldap-tools is needed while using Samba + LDAP. I sent an email do
 smbldap-tools developers about the problem and will update here when I get
 some more information about.

I did not yet dig into it in detail, but this seems a a wrong use in
smbldap-userlist.pl. I see there, that first the $attrs is 'assembled'
as a string in ['username','uidNumber','uid' . ] (line 198). Then
it passes to a Net::LDAP object:

cut-cut-cut-cut-cut-cut-
my  $mesg = $ldap_master-search ( base   = $base,
   scope = $config{scope},
   filter = $filter,
   attrs = $attrs
   );
cut-cut-cut-cut-cut-cut-

In documentation of Net::LDAP you find the details to the search
options. In particular you see:

cut-cut-cut-cut-cut-cut-
=item attrs =Egt [ ATTR, ... ]

A list of attributes to be returned for each entry that matches the
search filter.

If not specified, then the server will return the attributes that are
specified as accessible by default given your bind credentials.

Certain additional attributes such as createTimestamp and other
operational attributes may also be available for the asking:

  $mesg = $ldap-search( ... ,
 attrs = ['createTimestamp']
   );

To retrieve the default attributes and additional ones, use '*'.

  $mesg = $ldap-search( ... ,
 attrs = ['*', 'createTimestamp']
   );

To retrieve no attributes (the server only returns the DNs of matching
entries), use '1.1':

  $mesg = $ldap-search( ... ,
 attrs = ['1.1']
   );
cut-cut-cut-cut-cut-cut-


So smbldap-userlist.pl. passes a string, where is should be a list.

Btw, you can reproduce the error message easily by:

cut-cut-cut-cut-cut-cut-
#!/usr/bin/perl

use strict 'refs';

my $attrs = [ 'foo', 'bar', ];

push @{$attrs}, 'foobar';

use Data::Dumper 'Dumper';
warn Dumper [$attrs];
cut-cut-cut-cut-cut-cut-

You see, here if you remove the use strict 'refs' again, it does not
throw out the Can't use string ([ 'foo', 'bar', ]) as an ARRAY ref
while strict refs in use at testcase_broken.pl line 7..

Correctly it would be:

cut-cut-cut-cut-cut-cut-
#!/usr/bin/perl

use strict 'refs';

my $attrs = [ 'foo', 'bar', ];

push @{$attrs}, 'foobar';

use Data::Dumper 'Dumper';
warn Dumper [$attrs];
cut-cut-cut-cut-cut-cut-

Conclusion: I'm more convinced that is a real bug in smbldap-tools and
we surely should not remove the use strict; from
libconvert-asn1-perl.

Regards,
Salvatore


signature.asc
Description: Digital signature