[Aptitude-devel] Bug#980035: aptitude: segmentation fault when starting aptitude

2021-01-13 Thread Vincent Lefevre
Package: aptitude
Version: 0.8.13-2+b1
Severity: grave
Justification: renders package unusable
Tags: security

I got a first "segmentation fault" just after updating ('u' in the TUI).
Now, each time I run aptitude, a segmentation occurs one second after
starting it.

I suppose that it doesn't like some data that have been fetched.
Tagging security for this reason.

The backtrace:

(gdb) bt
#0  0x7f4149ad4f1c in ?? () from /usr/lib/x86_64-linux-gnu/libapt-pkg.so.6.0
#1  0x7f4149ad64c4 in ?? () from /usr/lib/x86_64-linux-gnu/libapt-pkg.so.6.0
#2  0x7f4149ad87f6 in ?? () from /usr/lib/x86_64-linux-gnu/libapt-pkg.so.6.0
#3  0x7f4149ab96bd in pkgDebianIndexFile::Merge(pkgCacheGenerator&, 
OpProgress*) () from /usr/lib/x86_64-linux-gnu/libapt-pkg.so.6.0
#4  0x7f4149ad33b6 in ?? () from /usr/lib/x86_64-linux-gnu/libapt-pkg.so.6.0
#5  0x7f4149ad9c30 in ?? () from /usr/lib/x86_64-linux-gnu/libapt-pkg.so.6.0
#6  0x7f4149adbd05 in ?? () from /usr/lib/x86_64-linux-gnu/libapt-pkg.so.6.0
#7  0x5579892393ff in ?? ()
#8  0x557989242c83 in ?? ()
#9  0x5579890dc9f6 in ?? ()
#10 0x7f4148f5cd0a in __libc_start_main (main=0x5579890daae0, argc=1, 
argv=0x7fffbe441bf8, init=, fini=, 
rtld_fini=, stack_end=0x7fffbe441be8) at ../csu/libc-start.c:308
#11 0x5579890e5f2a in ?? ()

However, if I run "strace -f -o str.out aptitude", I don't always
get a segmentation fault. So there may be another reason.

It may be a bug in libapt-pkg6.0, or perhaps a change in the upgrade
to apt 2.1.17 triggered an existing issue in aptitude.

Here's the end of the str.out file when "strace -f -o str.out aptitude"
crashed:

2237416 
stat("/var/lib/apt/lists/ftp.fr.debian.org_debian_dists_experimental_main_binary-all_Packages",
 0x7ffdb54ba240) = -1 ENOENT (No such file or directory)
2237416 
stat("/var/lib/apt/lists/ftp.fr.debian.org_debian_dists_experimental_main_binary-all_Packages.xz",
 0x7ffdb54ba240) = -1 ENOENT (No such file or directory)
2237416 
stat("/var/lib/apt/lists/ftp.fr.debian.org_debian_dists_experimental_main_binary-all_Packages.bz2",
 0x7ffdb54ba240) = -1 ENOENT (No such file or directory)
2237416 
stat("/var/lib/apt/lists/ftp.fr.debian.org_debian_dists_experimental_main_binary-all_Packages.lzma",
 0x7ffdb54ba240) = -1 ENOENT (No such file or directory)
2237416 
stat("/var/lib/apt/lists/ftp.fr.debian.org_debian_dists_experimental_main_binary-all_Packages.gz",
 0x7ffdb54ba240) = -1 ENOENT (No such file or directory)
2237416 
stat("/var/lib/apt/lists/ftp.fr.debian.org_debian_dists_experimental_main_binary-all_Packages.lz4",
 0x7ffdb54ba240) = -1 ENOENT (No such file or directory)
2237416 
stat("/var/lib/apt/lists/ftp.fr.debian.org_debian_dists_experimental_main_binary-all_Packages.zst",
 0x7ffdb54ba240) = -1 ENOENT (No such file or directory)
2237416 
stat("/var/lib/apt/lists/ftp.fr.debian.org_debian_dists_experimental_main_binary-all_Packages.uncompressed",
 0x7ffdb54ba240) = -1 ENOENT (No such file or directory)
2237416 
stat("/var/lib/apt/lists/ftp.fr.debian.org_debian_dists_experimental_main_binary-all_Packages",
 0x7ffdb54ba330) = -1 ENOENT (No such file or directory)
2237416 
stat("/var/lib/apt/lists/ftp.fr.debian.org_debian_dists_experimental_main_i18n_Translation-en",
 {st_mode=S_IFREG|0644, st_size=1187463, ...}) = 0
2237416 
stat("/var/lib/apt/lists/ftp.fr.debian.org_debian_dists_experimental_main_i18n_Translation-en",
 {st_mode=S_IFREG|0644, st_size=1187463, ...}) = 0
2237416 
stat("/var/lib/apt/lists/ftp.fr.debian.org_debian_dists_experimental_main_i18n_Translation-en",
 {st_mode=S_IFREG|0644, st_size=1187463, ...}) = 0
2237416 
stat("/var/lib/apt/lists/ftp.fr.debian.org_debian_dists_experimental_main_i18n_Translation-en",
 {st_mode=S_IFREG|0644, st_size=1187463, ...}) = 0
2237416 
stat("/var/lib/apt/lists/ftp.fr.debian.org_debian_dists_experimental_main_i18n_Translation-en",
 {st_mode=S_IFREG|0644, st_size=1187463, ...}) = 0
2237416 
stat("/var/lib/apt/lists/ftp.fr.debian.org_debian_dists_experimental_main_i18n_Translation-en",
 {st_mode=S_IFREG|0644, st_size=1187463, ...}) = 0
2237416 openat(AT_FDCWD, 
"/var/lib/apt/lists/ftp.fr.debian.org_debian_dists_experimental_main_i18n_Translation-en",
 O_RDONLY) = 3
2237416 fcntl(3, F_SETFD, FD_CLOEXEC)   = 0
2237416 fstat(3, {st_mode=S_IFREG|0644, st_size=1187463, ...}) = 0
2237416 close(3)= 0
2237416 rt_sigaction(SIGTSTP, {sa_handler=SIG_IGN, sa_mask=[], 
sa_flags=SA_RESTORER|SA_RESTART, sa_restorer=0x7fc6f0289140}, 
{sa_handler=0x7fc6f0772ce0, sa_mask=[], sa_flags=SA_RESTORER|SA_RESTART, 
sa_restorer=0x7fc6f0289140}, 8) = 0
2237416 poll([{fd=0, events=POLLIN}], 1, 0) = 0 (Timeout)
2237416 poll([{fd=0, events=POLLIN}], 1, 0) = 0 (Timeout)
2237416 rt_sigaction(SIGTSTP, {sa_handler=0x7fc6f0772ce0, sa_mask=[], 
sa_flags=SA_RESTORER|SA_RESTART, sa_restorer=0x7fc6f0289140}, NULL, 8) = 0
2237416 rt_sigaction(SIGTSTP, {sa_handler=SIG_IGN, sa_mask=[], 
sa_flags=SA_RESTORER|SA_RESTART, sa_restorer=0x7fc6f0289140}, 
{s

[Aptitude-devel] Bug#980035: aptitude: segmentation fault when starting aptitude

2021-01-13 Thread Vincent Lefevre
On 2021-01-13 10:29:17 +0100, Vincent Lefevre wrote:
> However, if I run "strace -f -o str.out aptitude", I don't always
> get a segmentation fault. So there may be another reason.

When it crashes, this seems to be at the same place:

[...]
2237416 read(3, "ym_19981025-8_amd64.deb\nSize: 11"..., 32324) = 32324
2237416 read(3, "ds: libcolorhug2 (= 1.4.5-3)\nDes"..., 32604) = 32604
2237416 read(3, "62e8f4b0 baeda553779dac49b00a6b2"..., 32336) = 32336
2237416 read(3, "83243673985ebc90635ba4337487ab 9"..., 17767) = 17767
2237416 read(3, "256: 588bb0e2a387be5494af07d9909"..., 32237) = 32237
2237416 read(3, "5688ba1f31dcc90cda9499 14b2ffe0c"..., 32391) = 32391
2237416 read(3, "2ecd4ea9d8b9d23afa9d5b67d7b8f2a3"..., 32481) = 32481
2237416 read(3, "fbef99d590e1cac8f0801e2fbcd2835e"..., 32449) = 32449
2237416 mremap(0x7fc6dc60, 60817408, 61865984, MREMAP_MAYMOVE) = 
0x7fc6d450
2237416 --- SIGSEGV {si_signo=SIGSEGV, si_code=SEGV_MAPERR, 
si_addr=0x7fc6dffef750} ---
[...]

[...]
223 read(3, "ym_19981025-8_amd64.deb\nSize: 11"..., 32324) = 32324
223 read(3, "ds: libcolorhug2 (= 1.4.5-3)\nDes"..., 32604) = 32604
223 read(3, "62e8f4b0 baeda553779dac49b00a6b2"..., 32336) = 32336
223 read(3, "83243673985ebc90635ba4337487ab 9"..., 17767) = 17767
223 read(3, "256: 588bb0e2a387be5494af07d9909"..., 32237) = 32237
223 read(3, "5688ba1f31dcc90cda9499 14b2ffe0c"..., 32391) = 32391
223 read(3, "2ecd4ea9d8b9d23afa9d5b67d7b8f2a3"..., 32481) = 32481
223 read(3, "fbef99d590e1cac8f0801e2fbcd2835e"..., 32449) = 32449
223 mremap(0x7fad2860, 60817408, 61865984, MREMAP_MAYMOVE) = 
0x7fad2050
223 --- SIGSEGV {si_signo=SIGSEGV, si_code=SEGV_MAPERR, 
si_addr=0x7fad2bfef750} ---
[...]

[...]
2238354 read(3, "ym_19981025-8_amd64.deb\nSize: 11"..., 32324) = 32324
2238354 read(3, "ds: libcolorhug2 (= 1.4.5-3)\nDes"..., 32604) = 32604
2238354 read(3, "62e8f4b0 baeda553779dac49b00a6b2"..., 32336) = 32336
2238354 read(3, "83243673985ebc90635ba4337487ab 9"..., 17767) = 17767
2238354 read(3, "256: 588bb0e2a387be5494af07d9909"..., 32237) = 32237
2238354 read(3, "5688ba1f31dcc90cda9499 14b2ffe0c"..., 32391) = 32391
2238354 read(3, "2ecd4ea9d8b9d23afa9d5b67d7b8f2a3"..., 32481) = 32481
2238354 read(3, "fbef99d590e1cac8f0801e2fbcd2835e"..., 32449) = 32449
2238354 mremap(0x7f975460, 60817408, 61865984, MREMAP_MAYMOVE) = 
0x7f974c50
2238354 --- SIGSEGV {si_signo=SIGSEGV, si_code=SEGV_MAPERR, 
si_addr=0x7f9757fef750} ---
[...]

And when it doesn't:

[...]
2237967 read(3, "ym_19981025-8_amd64.deb\nSize: 11"..., 32324) = 32324
2237967 read(3, "ds: libcolorhug2 (= 1.4.5-3)\nDes"..., 32604) = 32604
2237967 read(3, "62e8f4b0 baeda553779dac49b00a6b2"..., 32336) = 32336
2237967 read(3, "83243673985ebc90635ba4337487ab 9"..., 17767) = 17767
2237967 read(3, "256: 588bb0e2a387be5494af07d9909"..., 32237) = 32237
2237967 read(3, "5688ba1f31dcc90cda9499 14b2ffe0c"..., 32391) = 32391
2237967 read(3, "2ecd4ea9d8b9d23afa9d5b67d7b8f2a3"..., 32481) = 32481
2237967 read(3, "fbef99d590e1cac8f0801e2fbcd2835e"..., 32449) = 32449
2237967 mremap(0x7ff909d0, 60817408, 61865984, MREMAP_MAYMOVE) = 
0x7ff909d0
2237967 read(3, "b\n\nPackage: cue2toc-dbgsym\nSourc"..., 32156) = 32156
2237967 read(3, "fc5e9475f8ea1996ad1d1\nDescriptio"..., 32468) = 32468
2237967 read(3, "noit \nArch"..., 32635) = 32635
2237967 read(3, "446f87a121ed255bd081 e3830a9a187"..., 26866) = 26866
[...]

-- 
Vincent Lefèvre  - Web: 
100% accessible validated (X)HTML - Blog: 
Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)

___
Aptitude-devel mailing list
Aptitude-devel@alioth-lists.debian.net
https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/aptitude-devel

[Aptitude-devel] Bug#980035: aptitude: segmentation fault when starting aptitude

2021-01-13 Thread Vincent Lefevre
A bundle is available for a limited time:

  https://www.vinc17.net/aptitude-segv.bundle

I can reproduce the crash (but not always) with

  aptitude-run-state-bundle aptitude-segv.bundle

on this machine and on another one.

-- 
Vincent Lefèvre  - Web: 
100% accessible validated (X)HTML - Blog: 
Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)

___
Aptitude-devel mailing list
Aptitude-devel@alioth-lists.debian.net
https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/aptitude-devel

[Aptitude-devel] Bug#980035: aptitude: segmentation fault when starting aptitude

2021-01-13 Thread Vincent Lefevre
On 2021-01-13 11:24:33 +0100, Vincent Lefevre wrote:
> A bundle is available for a limited time:
> 
>   https://www.vinc17.net/aptitude-segv.bundle
> 
> I can reproduce the crash (but not always) with
> 
>   aptitude-run-state-bundle aptitude-segv.bundle
> 
> on this machine and on another one.

When it doesn't crash, aptitude doesn't suggest any action.

But on a 3rd machine, which has the same aptitude version, but older
versions of dependencies, aptitude never crashes, and I get:

[1(1)/...] Actions: 2 keeps, 1 upgrade
e: Examine  !: Apply  .: Next  ,: Previous

and 'e' says:

Packages  Resolve Dependencies
  --\ Keep the following packages at their current version: 
desktop-file-utils [0.26-1 (now, testing, unstable)]
gvfs-common  [1.46.1-2 (now, testing, unstable)]
  --\ Upgrade the following packages:
libmtp-common [1.1.17-3 now, testing, unstable -> 1.1.18-1 experimental]

(suggesting to upgrade a package to experimental like that is
incorrect, unless aptitude already broke the system).

-- 
Vincent Lefèvre  - Web: 
100% accessible validated (X)HTML - Blog: 
Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)

___
Aptitude-devel mailing list
Aptitude-devel@alioth-lists.debian.net
https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/aptitude-devel

[Aptitude-devel] Bug#980035: Bug#980035: aptitude: segmentation fault when starting aptitude

2021-01-13 Thread Julian Andres Klode
On Wed, Jan 13, 2021 at 10:29:17AM +0100, Vincent Lefevre wrote:
> Package: aptitude
> Version: 0.8.13-2+b1
> Severity: grave
> Justification: renders package unusable
> Tags: security
> 
> I got a first "segmentation fault" just after updating ('u' in the TUI).
> Now, each time I run aptitude, a segmentation occurs one second after
> starting it.
> 
> I suppose that it doesn't like some data that have been fetched.
> Tagging security for this reason.

Smells like 980037? Bug in APT's cache building upon mremap() in new
code path in 2.1.16/17.

-- 
debian developer - deb.li/jak | jak-linux.org - free software dev
ubuntu core developer  i speak de, en

___
Aptitude-devel mailing list
Aptitude-devel@alioth-lists.debian.net
https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/aptitude-devel

[Aptitude-devel] Bug#980035: Bug#980035: aptitude: segmentation fault when starting aptitude

2021-01-13 Thread Vincent Lefevre
On 2021-01-13 12:31:05 +0100, Julian Andres Klode wrote:
> Smells like 980037? Bug in APT's cache building upon mremap() in new
> code path in 2.1.16/17.

Yes, I first rebuilt apt, and

  aptitude-run-state-bundle aptitude-segv.bundle

was still crashing, then applied the patch suggested at

  https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=980037#10

and I no longer get any crash.

But I don't have a patched kernel, just the one provided by Debian,
and the crashes were almost 100% reproducible when "aptitude" was
run alone.

-- 
Vincent Lefèvre  - Web: 
100% accessible validated (X)HTML - Blog: 
Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)

___
Aptitude-devel mailing list
Aptitude-devel@alioth-lists.debian.net
https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/aptitude-devel

[Aptitude-devel] Bug#980035: Bug#980035: Bug#980035: aptitude: segmentation fault when starting aptitude

2021-01-13 Thread Axel Beckert
Control: clone -1 -2
Control: retile -2 aptitude-create-state-bundle should include more files from 
file:/// URLs
Control: severity -2 minor
Control: submitter -2 Axel Beckert 
Control: tag -2 - security

Hi Julian and Vincent,

Julian Andres Klode wrote:
> > I got a first "segmentation fault" just after updating ('u' in the TUI).
> > Now, each time I run aptitude, a segmentation occurs one second after
> > starting it.

H, works still fine for me so far with 2.1.17.

> > I suppose that it doesn't like some data that have been fetched.
> > Tagging security for this reason.
> 
> Smells like 980037?

Yep, smells like something which came in with apt 2.1.17.

> Bug in APT's cache building upon mremap() in new code path in
> 2.1.16/17.

I'd rather guess 2.1.17 only given the time of the bug report.

Then again, I so far didn't run into it, neither with "aptitude -u"
(as I usually do on several boxes several times per day) nor with
pressing "u" inside the TUI.

Vincent: Got the bundle, thanks! Wasn't able to provoke a segfault
with it, even not after pressing "u". But as mentioned in #980037 this
seems normal in such a case without a special kernel. So thanks for
the bug report!

Then again, it argued about some missing files. Seems as if
aptitude-create-state-bundle should copy way more files when handling
file:/// URLs:

# aptitude-run-state-bundle ~abe/aptitude/aptitude-segv-#980035.bundle aptitude 
update
[…]
Get: 33 file:/var/local/apt ./ Packages
Err file:/var/local/apt ./ Packages
  File not found - /var/local/apt/./Packages (2: No such file or directory)
Get: 34 file:/var/local/apt ./ Translation-en
[…]  
Fetched 87.9 MB in 10s (8426 kB/s)
W: Download is performed unsandboxed as root as file 
'/tmp/aptitudebug.9E6xy9EY0/var/lib/apt/lists/partial/ftp.fr.debian.org_debian_dists_stable_InRelease'
 couldn't be accessed by user '_apt'. - pkgAcquire::Run (13: Permission denied)
E: Failed to download some files
[…]
W: Failed to fetch file:/var/local/apt/./Packages: File not found - 
/var/local/apt/./Packages (2: No such file or directory)
E: Some index files failed to download. They have been ignored, or old ones 
used instead.

Created a new bug report for that.

Regards, Axel
-- 
 ,''`.  |  Axel Beckert , https://people.debian.org/~abe/
: :' :  |  Debian Developer, ftp.ch.debian.org Admin
`. `'   |  4096R: 2517 B724 C5F6 CA99 5329  6E61 2FF9 CD59 6126 16B5
  `-|  1024D: F067 EA27 26B9 C3FC 1486  202E C09E 1D89 9593 0EDE

___
Aptitude-devel mailing list
Aptitude-devel@alioth-lists.debian.net
https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/aptitude-devel

[Aptitude-devel] Processed (with 1 error): Re: Bug#980035: Bug#980035: aptitude: segmentation fault when starting aptitude

2021-01-13 Thread Debian Bug Tracking System
Processing control commands:

> clone -1 -2
Bug #980035 [aptitude] aptitude: segmentation fault when starting aptitude
Bug 980035 cloned as bug 980053
> retile -2 aptitude-create-state-bundle should include more files from 
> file:/// URLs
Unknown command or malformed arguments to command.

> severity -2 minor
Bug #980053 [aptitude] aptitude: segmentation fault when starting aptitude
Severity set to 'minor' from 'grave'
> submitter -2 Axel Beckert 
Bug #980053 [aptitude] aptitude: segmentation fault when starting aptitude
Changed Bug submitter to 'Axel Beckert ' from 'Vincent Lefevre 
'.
> tag -2 - security
Bug #980053 [aptitude] aptitude: segmentation fault when starting aptitude
Removed tag(s) security.

-- 
980035: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=980035
980053: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=980053
Debian Bug Tracking System
Contact ow...@bugs.debian.org with problems

___
Aptitude-devel mailing list
Aptitude-devel@alioth-lists.debian.net
https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/aptitude-devel

[Aptitude-devel] Processed: retitle 980053 to aptitude-create-state-bundle should include more files from file:/// URLs

2021-01-13 Thread Debian Bug Tracking System
Processing commands for cont...@bugs.debian.org:

> retitle 980053 aptitude-create-state-bundle should include more files from 
> file:/// URLs
Bug #980053 [aptitude] aptitude: segmentation fault when starting aptitude
Changed Bug title to 'aptitude-create-state-bundle should include more files 
from file:/// URLs' from 'aptitude: segmentation fault when starting aptitude'.
> thanks
Stopping processing here.

Please contact me if you need assistance.
-- 
980053: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=980053
Debian Bug Tracking System
Contact ow...@bugs.debian.org with problems

___
Aptitude-devel mailing list
Aptitude-devel@alioth-lists.debian.net
https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/aptitude-devel

[Aptitude-devel] Bug#980035: Bug#980035: aptitude: segmentation fault when starting aptitude

2021-01-13 Thread Vincent Lefevre
On 2021-01-13 14:46:21 +0100, Vincent Lefevre wrote:
> On 2021-01-13 12:31:05 +0100, Julian Andres Klode wrote:
> > Smells like 980037? Bug in APT's cache building upon mremap() in new
> > code path in 2.1.16/17.
> 
> Yes, I first rebuilt apt, and
> 
>   aptitude-run-state-bundle aptitude-segv.bundle
> 
> was still crashing, then applied the patch suggested at
> 
>   https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=980037#10
> 
> and I no longer get any crash.

Hmm... I think that you should forget that test. I thought
that aptitude-run-state-bundle would only depend on files from
aptitude-segv.bundle, but it still reads some other files from
/var/lib according to strace. And now I get

--- Upgradable Packages (65)

instead of

--- Upgradable Packages (61)

Since the crashes are very sensitive to the system status, the
above test might not be reliable.

-- 
Vincent Lefèvre  - Web: 
100% accessible validated (X)HTML - Blog: 
Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)

___
Aptitude-devel mailing list
Aptitude-devel@alioth-lists.debian.net
https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/aptitude-devel

[Aptitude-devel] Bug#980035: aptitude: segmentation fault when starting aptitude

2021-01-13 Thread Vincent Lefevre
On 2021-01-13 12:04:57 +0100, Vincent Lefevre wrote:
> On 2021-01-13 11:24:33 +0100, Vincent Lefevre wrote:
> > A bundle is available for a limited time:
> > 
> >   https://www.vinc17.net/aptitude-segv.bundle
> > 
> > I can reproduce the crash (but not always) with
> > 
> >   aptitude-run-state-bundle aptitude-segv.bundle
> > 
> > on this machine and on another one.
> 
> When it doesn't crash, aptitude doesn't suggest any action.
> 
> But on a 3rd machine, which has the same aptitude version, but older
> versions of dependencies, aptitude never crashes, and I get:
> 
> [1(1)/...] Actions: 2 keeps, 1 upgrade
> e: Examine  !: Apply  .: Next  ,: Previous
> 
> and 'e' says:
> 
> Packages  Resolve Dependencies
>   --\ Keep the following packages at their current version:   
>   
> desktop-file-utils [0.26-1 (now, testing, 
> unstable)]
> gvfs-common  [1.46.1-2 (now, testing, 
> unstable)]
>   --\ Upgrade the following packages:
> libmtp-common [1.1.17-3 now, testing, unstable -> 1.1.18-1 
> experimental]
> 
> (suggesting to upgrade a package to experimental like that is
> incorrect, unless aptitude already broke the system).

The cause of this issue seems to be that aptitude-run-state-bundle
depends on the current system status, not just aptitude-segv.bundle.

-- 
Vincent Lefèvre  - Web: 
100% accessible validated (X)HTML - Blog: 
Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)

___
Aptitude-devel mailing list
Aptitude-devel@alioth-lists.debian.net
https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/aptitude-devel

[Aptitude-devel] Bug#980035: Bug#980035: Bug#980035: aptitude: segmentation fault when starting aptitude

2021-01-13 Thread Axel Beckert
Hi,

Vincent Lefevre wrote:
> Hmm... I think that you should forget that test. I thought
> that aptitude-run-state-bundle would only depend on files from
> aptitude-segv.bundle, but it still reads some other files from
> /var/lib according to strace. And now I get
> 
> --- Upgradable Packages (65)
> 
> instead of
> 
> --- Upgradable Packages (61)
> 
> Since the crashes are very sensitive to the system status, the
> above test might not be reliable.

Ack. That's now https://bugs.debian.org/980053 :-)

Regards, Axel
-- 
 ,''`.  |  Axel Beckert , https://people.debian.org/~abe/
: :' :  |  Debian Developer, ftp.ch.debian.org Admin
`. `'   |  4096R: 2517 B724 C5F6 CA99 5329  6E61 2FF9 CD59 6126 16B5
  `-|  1024D: F067 EA27 26B9 C3FC 1486  202E C09E 1D89 9593 0EDE

___
Aptitude-devel mailing list
Aptitude-devel@alioth-lists.debian.net
https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/aptitude-devel

[Aptitude-devel] Bug#980035: Bug#980035: Bug#980035: aptitude: segmentation fault when starting aptitude

2021-01-13 Thread Vincent Lefevre
On 2021-01-13 15:07:26 +0100, Axel Beckert wrote:
> Vincent: Got the bundle, thanks! Wasn't able to provoke a segfault
> with it, even not after pressing "u".

With the bundle, the crash occurs while the UI isn't displayed yet.
But I can see in particular:

2300077 stat("/var/lib/dpkg/status", {st_mode=S_IFREG|0644, st_size=3777850, 
...}) = 0
2300081 openat(AT_FDCWD, "/var/lib/dpkg/arch", O_RDONLY) = -1 ENOENT (No such 
file or directory)
2300082 openat(AT_FDCWD, "/var/lib/dpkg/arch", O_RDONLY) = -1 ENOENT (No such 
file or directory)
2300083 openat(AT_FDCWD, "/var/lib/dpkg/arch", O_RDONLY) = -1 ENOENT (No such 
file or directory)
2300077 stat("/var/lib/apt-xapian-index/index", {st_mode=S_IFREG|0644, 
st_size=41, ...}) = 0
2300077 openat(AT_FDCWD, "/var/lib/apt-xapian-index/index", O_RDONLY) = 36
2300077 openat(AT_FDCWD, "/var/lib/aptitude//pkgstates", O_RDONLY) = 36
2300077 openat(AT_FDCWD, "/var/lib/debtags/package-tags", O_RDONLY) = -1 ENOENT 
(No such file or directory)
222 symlinkat("/var/local/apt/./Packages", 4, 
".//var/lib/apt/lists/_var_local_apt_._Packages") = 0

while most files are read from the /tmp version.

So, as this seems to depend on the system, this is not surprising.
When I look in detail:

--\ Upgradable Packages (65)
  --\ admin  Administrative utilities (install software, manage users, e
--\ main   The main Debian archive (3)
i   apt2.1.17   2.1.17+local1
i   apt-utils  2.1.17   2.1.17+local1
[...]

The 2.1.17+local1 packages are the newly reinstalled patched versions
(now listed in /var/local/apt/Packages).

They do not exist in the bundle!!!

> But as mentioned in #980037 this seems normal in such a case without
> a special kernel. So thanks for the bug report!

Note that I do *not* have a special kernel. So this is unrelated.

-- 
Vincent Lefèvre  - Web: 
100% accessible validated (X)HTML - Blog: 
Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)

___
Aptitude-devel mailing list
Aptitude-devel@alioth-lists.debian.net
https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/aptitude-devel

[Aptitude-devel] Bug#980053: Bug#980035: Bug#980035: aptitude: segmentation fault when starting aptitude

2021-01-13 Thread Vincent Lefevre
[moved to Cc: 980053]

Hi,

On 2021-01-13 15:33:00 +0100, Axel Beckert wrote:
> Vincent Lefevre wrote:
> > Hmm... I think that you should forget that test. I thought
> > that aptitude-run-state-bundle would only depend on files from
> > aptitude-segv.bundle, but it still reads some other files from
> > /var/lib according to strace. And now I get
> > 
> > --- Upgradable Packages (65)
> > 
> > instead of
> > 
> > --- Upgradable Packages (61)
> > 
> > Since the crashes are very sensitive to the system status, the
> > above test might not be reliable.
> 
> Ack. That's now https://bugs.debian.org/980053 :-)

Well, 980053 is about aptitude-create-state-bundle. The above issue
is about aptitude-run-state-bundle. Perhaps this is due to the
aptitude-create-state-bundle bug, but I think that if a file is
missing, aptitude-run-state-bundle should fail, not fall back to
/var/lib files.

-- 
Vincent Lefèvre  - Web: 
100% accessible validated (X)HTML - Blog: 
Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)

___
Aptitude-devel mailing list
Aptitude-devel@alioth-lists.debian.net
https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/aptitude-devel

[Aptitude-devel] Bug#980035: Bug#980035: aptitude: segmentation fault when starting aptitude

2021-01-13 Thread Axel Beckert
Control: clone -1 -2
Control: retitle -2 aptitude-run-state-bundle: uses some local files instead of 
only those from the bundle
Control: tag -2 - security
Control: tag -1 + moreinfo
Control: severity -2 normal

Hi Vincent,

Vincent Lefevre wrote:
> With the bundle, the crash occurs while the UI isn't displayed yet.
> But I can see in particular:
> 
> 2300077 stat("/var/lib/dpkg/status", {st_mode=S_IFREG|0644, st_size=3777850, 
> ...}) = 0
> 2300081 openat(AT_FDCWD, "/var/lib/dpkg/arch", O_RDONLY) = -1 ENOENT (No such 
> file or directory)
> 2300082 openat(AT_FDCWD, "/var/lib/dpkg/arch", O_RDONLY) = -1 ENOENT (No such 
> file or directory)
> 2300083 openat(AT_FDCWD, "/var/lib/dpkg/arch", O_RDONLY) = -1 ENOENT (No such 
> file or directory)
> 2300077 stat("/var/lib/apt-xapian-index/index", {st_mode=S_IFREG|0644, 
> st_size=41, ...}) = 0
> 2300077 openat(AT_FDCWD, "/var/lib/apt-xapian-index/index", O_RDONLY) = 36
> 2300077 openat(AT_FDCWD, "/var/lib/aptitude//pkgstates", O_RDONLY) =
> 36


Yep, and the later seems to have bitten me a bit when testing the
bundle. At least chromium had no more forbidden version afterwards
which was unexpected.

Then again, /var/lib/aptitude//pkgstates is in your bundle as
.//var/lib/aptitude/pkgstates, so there's no reason for a fall-back or
so.

> 2300077 openat(AT_FDCWD, "/var/lib/debtags/package-tags", O_RDONLY) = -1 
> ENOENT (No such file or directory)
> 222 symlinkat("/var/local/apt/./Packages", 4, 
> ".//var/lib/apt/lists/_var_local_apt_._Packages") = 0
> 
> while most files are read from the /tmp version.
> 
> So, as this seems to depend on the system, this is not surprising.

Ack.

> > But as mentioned in #980037 this seems normal in such a case without
> > a special kernel. So thanks for the bug report!
> 
> Note that I do *not* have a special kernel.

I know. That's the reason why I mentioned this.

> So this is unrelated.

Not necessarily. It's possible. But IMHO unlikely.

Since Julian has uploaded a fix as apt/2.1.18, would you mind checking
if you can still reproduce the issue in any way?

Regards, Axel
-- 
 ,''`.  |  Axel Beckert , https://people.debian.org/~abe/
: :' :  |  Debian Developer, ftp.ch.debian.org Admin
`. `'   |  4096R: 2517 B724 C5F6 CA99 5329  6E61 2FF9 CD59 6126 16B5
  `-|  1024D: F067 EA27 26B9 C3FC 1486  202E C09E 1D89 9593 0EDE

___
Aptitude-devel mailing list
Aptitude-devel@alioth-lists.debian.net
https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/aptitude-devel

[Aptitude-devel] Processed: Re: Bug#980035: aptitude: segmentation fault when starting aptitude

2021-01-13 Thread Debian Bug Tracking System
Processing control commands:

> clone -1 -2
Bug #980035 [aptitude] aptitude: segmentation fault when starting aptitude
Bug 980035 cloned as bug 980075
> retitle -2 aptitude-run-state-bundle: uses some local files instead of only 
> those from the bundle
Bug #980075 [aptitude] aptitude: segmentation fault when starting aptitude
Changed Bug title to 'aptitude-run-state-bundle: uses some local files instead 
of only those from the bundle' from 'aptitude: segmentation fault when starting 
aptitude'.
> tag -2 - security
Bug #980075 [aptitude] aptitude-run-state-bundle: uses some local files instead 
of only those from the bundle
Removed tag(s) security.
> tag -1 + moreinfo
Bug #980035 [aptitude] aptitude: segmentation fault when starting aptitude
Added tag(s) moreinfo.
> severity -2 normal
Bug #980075 [aptitude] aptitude-run-state-bundle: uses some local files instead 
of only those from the bundle
Severity set to 'normal' from 'grave'

-- 
980035: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=980035
980075: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=980075
Debian Bug Tracking System
Contact ow...@bugs.debian.org with problems

___
Aptitude-devel mailing list
Aptitude-devel@alioth-lists.debian.net
https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/aptitude-devel

[Aptitude-devel] Bug#980035: Bug#980035: aptitude: segmentation fault when starting aptitude

2021-01-13 Thread Vincent Lefevre
On 2021-01-14 02:14:29 +0100, Axel Beckert wrote:
> Since Julian has uploaded a fix as apt/2.1.18, would you mind checking
> if you can still reproduce the issue in any way?

I couldn't manage to reproduce it with apt 2.1.18.

-- 
Vincent Lefèvre  - Web: 
100% accessible validated (X)HTML - Blog: 
Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)

___
Aptitude-devel mailing list
Aptitude-devel@alioth-lists.debian.net
https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/aptitude-devel