Bug#814929: libdata-uuid-libuuid-perl: FTBFS on ppc64el: test failure

Niko Tyni ntyni at debian.org
Sun Nov 27 12:13:37 UTC 2016


Control: severity -1 serious
Control: tag -1 patch

On Tue, Feb 16, 2016 at 12:14:06PM -0500, Fernando Seiti Furusato wrote:
> Source: libdata-uuid-libuuid-perl
> Severity: normal
> User: debian-powerpc at lists.debian.org
> Usertags: ppc64el

> The package libdata-uuid-libuuid-perl fails to build from source on
> ppc64el.

> > t/basic.t ... 1/47 
> > #   Failed test 'to_binary(obj)'
> > #   at t/basic.t line 68.
> > #          got: 'V�re::is'
> > #     expected: undef

Thanks for the report. This now fails on amd64 as well.

It looks like this happens when perl pointers use a memory
area that stringifies to 12 hex digits, so that the string
"Blah=HASH(0x555555f30d18)" is long enough to be a base64 encoded UUID
string. It's then blindly passed to MIME::Base64::decode_base64 in
sv_to_uuid(), and gets decoded only up to the '=' character, giving the
octal bytes 006 V 241 (with no trailing zero byte).

With fewer hex digits in the string sv_to_uuid() returns undef as expected.

The change on amd64 seems to be that for some reason, perl_5.24.1~rc4-1
uses different looking pointers than 5.24.1~rc3-3: "perl -le 'print \$a'"
gives SCALAR(0x55e0ecae4930) on sid but SCALAR(0x15a79f0) on stretch.
I suspect the difference is due to changed compiler / dpkg-buildflags
defaults for PIE.

A simple fix is to sanity check the length of the decoded value. Proposed
patch attached.
-- 
Niko Tyni   ntyni at debian.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-TODO-tests-for-base64-decoding-failures.patch
Type: text/x-diff
Size: 1555 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/pkg-perl-maintainers/attachments/20161127/ba17ec79/attachment.patch>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0002-Check-that-a-base64-decoded-string-is-long-enough-to.patch
Type: text/x-diff
Size: 1529 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/pkg-perl-maintainers/attachments/20161127/ba17ec79/attachment-0001.patch>


More information about the pkg-perl-maintainers mailing list